From 7938a9e589a441324b40af3b39bd1a5b8eb7f92a Mon Sep 17 00:00:00 2001 From: eap Date: Wed, 5 Mar 2008 10:28:46 +0000 Subject: [PATCH] + // find out side orientation, which is important if there are several wires (PAL19080) + bool isForward = true; + if ( nbWires > 1 ) { ... + } + StdMeshers_FaceSide* wire = new StdMeshers_FaceSide( theFace, wireEdges, &theMesh, - true, theIgnoreMediumNodes); + isForward, theIgnoreMediumNodes); --- src/StdMeshers/StdMeshers_FaceSide.cxx | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/src/StdMeshers/StdMeshers_FaceSide.cxx b/src/StdMeshers/StdMeshers_FaceSide.cxx index 5850cb74e..eccc3f5af 100644 --- a/src/StdMeshers/StdMeshers_FaceSide.cxx +++ b/src/StdMeshers/StdMeshers_FaceSide.cxx @@ -44,6 +44,7 @@ #include #include #include +#include #include #include #include @@ -505,12 +506,20 @@ TSideVector StdMeshers_FaceSide::GetFaceWires(const TopoDS_Face& theFace, return TSideVector(0); } } + // find out side orientation, which is important if there are several wires (PAL19080) + bool isForward = true; + if ( nbWires > 1 ) { + TopExp_Explorer e( theFace, TopAbs_EDGE ); + while ( ! e.Current().IsSame( wireEdges.back() )) + e.Next(); + isForward = ( e.Current().Orientation() == wireEdges.back().Orientation() ); + } + StdMeshers_FaceSide* wire = new StdMeshers_FaceSide( theFace, wireEdges, &theMesh, - true, theIgnoreMediumNodes); + isForward, theIgnoreMediumNodes); wires[ iW ] = StdMeshers_FaceSidePtr( wire ); from = to; } return wires; } - -- 2.39.2