From ddd95bbf9a5a7ef4d741bb818b81a5b7c0491c94 Mon Sep 17 00:00:00 2001 From: pkv Date: Fri, 18 Jan 2013 12:10:48 +0400 Subject: [PATCH] 0023676: Intersection between edge and a face produces extra vertex --- src/IntTools/IntTools_EdgeFace.cxx | 15 ++++++++------- tests/bugs/modalg/bug23676 | 26 ++++++++++++++++++++++++++ 2 files changed, 34 insertions(+), 7 deletions(-) create mode 100755 tests/bugs/modalg/bug23676 diff --git a/src/IntTools/IntTools_EdgeFace.cxx b/src/IntTools/IntTools_EdgeFace.cxx index b0a4912cb0..c8f3872be8 100755 --- a/src/IntTools/IntTools_EdgeFace.cxx +++ b/src/IntTools/IntTools_EdgeFace.cxx @@ -1415,11 +1415,12 @@ void IntTools_EdgeFace::CheckData() Standard_Real& aTx) { Standard_Real aTF, aTL, Tol, U1f,U1l,V1f,V1l, af, al,aDist2, aMinDist2, aTm, aDist2New; + Standard_Real aEpsT; Standard_Boolean theflag=Standard_False; Standard_Integer aNbExt, i, iLower ; aCP.Range1(aTF, aTL); - + aEpsT=8.e-5; aTm=0.5*(aTF+aTL); aDist2=DistanceFunction(aTm); aDist2 *= aDist2; @@ -1473,15 +1474,15 @@ void IntTools_EdgeFace::CheckData() Extrema_POnSurf aPOnS; anExtrema.Points(iLower, aPOnC, aPOnS); - + aTx=aPOnC.Parameter(); - - if (fabs (aTx-aTF) < myEpsT) { - return !theflag; + /// + if (fabs (aTx-aTF) < aEpsT) { + return theflag; } - if (fabs (aTx-aTL) < myEpsT) { - return !theflag; + if (fabs (aTx-aTL) < aEpsT) { + return theflag; } if (aTx>aTF && aTx