Salome HOME
Regression of 21397: a quadrangle face mesh can't be projected to a cylinder
authoreap <eap@opencascade.com>
Fri, 17 Oct 2014 16:26:57 +0000 (20:26 +0400)
committereap <eap@opencascade.com>
Fri, 17 Oct 2014 16:26:57 +0000 (20:26 +0400)
src/SMESH/SMESH_MesherHelper.cxx
src/StdMeshers/StdMeshers_Projection_2D.cxx

index 4449efbce31db19f2ce544689a35d68281427b22..21b0043c95897f4584e7a1417ab91296ff0feeca 100644 (file)
@@ -2574,11 +2574,13 @@ bool SMESH_MesherHelper::IsDistorted2D( SMESH_subMesh* faceSM )
     }
     // prepare to getting UVs
     const SMDS_MeshNode* inFaceNode = 0;
-    if ( helper.HasSeam() )
+    if ( helper.HasSeam() ) {
       for ( size_t i = 0; ( i < nodes.size() && !inFaceNode ); ++i )
         if ( !helper.IsSeamShape( nodes[ i ]->getshapeId() ))
           inFaceNode = nodes[ i ];
-
+      if ( !inFaceNode )
+        continue;
+    }
     // get UVs
     uv.resize( nodes.size() );
     for ( size_t i = 0; i < nodes.size(); ++i )
index 9db5ee4c32c16d28f41e21af8d4879b85a132579..66e7834aec0cf2846de4d283b1309f30f899284c 100644 (file)
@@ -1047,7 +1047,7 @@ bool StdMeshers_Projection_2D::Compute(SMESH_Mesh& theMesh, const TopoDS_Shape&
 
   bool done = false;
 
- if ( !done )
 if ( !done )
   {
     // try to project from the same face with different location
     done = projectPartner( tgtFace, srcFace, tgtWires, srcWires,