mirror of
https://git.salome-platform.org/gitpub/modules/smesh.git
synced 2025-02-05 22:04:18 +05:00
[SALOME platform 0019943]: Pb with projection 2d
In SMESH_Pattern::Load(mesh,face), fix treating seam vertices of not seam edges
This commit is contained in:
parent
4ecc1e1c81
commit
ff5e5d0e73
@ -631,12 +631,13 @@ bool SMESH_Pattern::Load (SMESH_Mesh* theMesh,
|
|||||||
|
|
||||||
// vertices
|
// vertices
|
||||||
for ( elIt = eList.begin(); elIt != eList.end(); elIt++ ) {
|
for ( elIt = eList.begin(); elIt != eList.end(); elIt++ ) {
|
||||||
|
int nbV = myShapeIDMap.Extent();
|
||||||
myShapeIDMap.Add( TopExp::FirstVertex( *elIt, true ));
|
myShapeIDMap.Add( TopExp::FirstVertex( *elIt, true ));
|
||||||
if ( helper.IsSeamShape( *elIt ) ) {
|
bool added = ( nbV < myShapeIDMap.Extent() );
|
||||||
// vertices present twice in the wire have two corresponding key points
|
if ( !added ) { // vertex encountered twice
|
||||||
const TopoDS_Vertex& lastV = TopExp::LastVertex( *elIt, true );
|
// a seam vertex have two corresponding key points
|
||||||
if ( helper.IsRealSeam( lastV ))
|
myShapeIDMap.Add( TopExp::FirstVertex( *elIt, true ).Reversed());
|
||||||
myShapeIDMap.Add( lastV );// vertex orienation is REVERSED
|
++nbNodes;
|
||||||
}
|
}
|
||||||
if ( SMESHDS_SubMesh * eSubMesh = aMeshDS->MeshElements( *elIt ))
|
if ( SMESHDS_SubMesh * eSubMesh = aMeshDS->MeshElements( *elIt ))
|
||||||
nbNodes += eSubMesh->NbNodes() + 1;
|
nbNodes += eSubMesh->NbNodes() + 1;
|
||||||
@ -677,7 +678,7 @@ bool SMESH_Pattern::Load (SMESH_Mesh* theMesh,
|
|||||||
else { // on CLOSED edge (i.e. having one vertex with different orienations)
|
else { // on CLOSED edge (i.e. having one vertex with different orienations)
|
||||||
for ( int is2 = 0; is2 < 2; ++is2 ) {
|
for ( int is2 = 0; is2 < 2; ++is2 ) {
|
||||||
TopoDS_Shape & v = is2 ? v2 : v1;
|
TopoDS_Shape & v = is2 ? v2 : v1;
|
||||||
if ( helper.IsSeamShape( v ) ) {
|
if ( helper.IsRealSeam( v ) ) {
|
||||||
// reverse or not depending on orientation of adjacent seam
|
// reverse or not depending on orientation of adjacent seam
|
||||||
TopoDS_Edge seam;
|
TopoDS_Edge seam;
|
||||||
list<TopoDS_Edge>::iterator eIt2 = elIt;
|
list<TopoDS_Edge>::iterator eIt2 = elIt;
|
||||||
|
Loading…
Reference in New Issue
Block a user