From: eap Date: Thu, 17 Apr 2014 11:56:40 +0000 (+0400) Subject: 22245: [CEA] Method to get the minimal link length X-Git-Tag: V7_4_0rc1~46 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=45a71c446766d932304a0cbd6420bb70886116b5;p=modules%2Fsmesh.git 22245: [CEA] Method to get the minimal link length Add Mesh.GetMinMax() --- diff --git a/src/SMESH_SWIG/smeshBuilder.py b/src/SMESH_SWIG/smeshBuilder.py index ce0a35594..778b72c3b 100644 --- a/src/SMESH_SWIG/smeshBuilder.py +++ b/src/SMESH_SWIG/smeshBuilder.py @@ -4629,6 +4629,19 @@ class Mesh: def GetSkew(self, elemId): return self._valueFromFunctor(SMESH.FT_Skew, elemId) + ## Return minimal and maximal value of a given functor. + # @param funType a functor type, an item of SMESH.FunctorType enum + # (one of SMESH.FunctorType._items) + # @return tuple (min,max) + # @ingroup l1_measurements + def GetMinMax(self, funType): + fun = self._getFunctor( funType ) + if fun: + hist = fun.GetHistogram( 1, False ) + if hist: + return hist[0].min, hist[0].max + return None + pass # end of Mesh class ## Helper class for wrapping of SMESH.SMESH_Pattern CORBA class