Salome HOME
[SALOME platform 0019316]: Need to have a better interface with GHS3D diagnostics
authoreap <eap@opencascade.com>
Mon, 21 Jul 2008 09:50:39 +0000 (09:50 +0000)
committereap <eap@opencascade.com>
Mon, 21 Jul 2008 09:50:39 +0000 (09:50 +0000)
   fix for algos not needing shapes

src/SMESH_SWIG/smeshDC.py

index dfeeb306c945ae59af77ba3c3472d7833ab50791..9b77ceaa5b8a03569f31b557db2887536a27e975 100644 (file)
@@ -205,6 +205,8 @@ def TreatHypoStatus(status, hypName, geomName, isAlgo):
         reason = "it is hidden by an algorithm of an upper dimension, which generates elements of all dimensions"
     elif status == HYP_HIDING_ALGO:
         reason = "it hides algorithms of lower dimensions by generating elements of all dimensions"
+    elif status == HYP_NEED_SHAPE:
+        reason = "Algorithm can't work without shape"
     else:
         return
     hypName = '"' + hypName + '"'
@@ -574,6 +576,9 @@ class Mesh:
         elif obj != 0:
             SetName(self.mesh, GetName(obj))
 
+        if not self.geom:
+            self.geom = self.mesh.GetShapeToMesh()
+
         self.editor = self.mesh.GetMeshEditor()
 
     ## Initializes the Mesh object from an instance of SMESH_Mesh interface