Salome HOME
[bos #40653][CEA] New mesh import export formats with meshio.
[modules/smesh.git] / src / SMESH / SMESH_subMesh.cxx
index a019213ee52285ec5979354d8f8257b8d768211d..18b6c3cdfe9687603d1dea4f8dacc19b5806ea71 100644 (file)
@@ -1,4 +1,4 @@
-// Copyright (C) 2007-2023  CEA, EDF, OPEN CASCADE
+// Copyright (C) 2007-2024  CEA, EDF, OPEN CASCADE
 //
 // Copyright (C) 2003-2007  OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
 // CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
@@ -891,7 +891,10 @@ SMESH_Hypothesis::Hypothesis_Status
           ret = SMESH_Hypothesis::HYP_INCOMPATIBLE;
       }
       else if (!_father->IsUsedHypothesis( anHyp, this ))
-        ret = SMESH_Hypothesis::HYP_INCOMPATIBLE;
+      {
+        if ( anHyp->GetDim() == this->GetAlgo()->GetDim() )
+          ret = SMESH_Hypothesis::HYP_INCOMPATIBLE;
+      }
 
       if (SMESH_Hypothesis::IsStatusFatal( ret ))
       {
@@ -1517,7 +1520,7 @@ bool SMESH_subMesh::ComputeStateEngine(compute_event event)
         // check submeshes needed
         // When computing in parallel mode we do not have a additional layer of submesh
         // The check should not be done in parallel as that check is not thread-safe
-        if (_father->HasShapeToMesh() && (!_father->IsParallel() || shape.ShapeType() != TopAbs_SOLID )) {
+        if (_father->HasShapeToMesh() && (!_father->IsParallel() || shape.ShapeType() != _father->GetParallelElement() )) {
           bool subComputed = false, subFailed = false;
           if (!algo->OnlyUnaryInput()) {
             //  --- commented for bos#22320 to compute all sub-shapes at once if possible;