X-Git-Url: http://git.dev.opencascade.org/gitweb/?p=occt.git;a=blobdiff_plain;f=src%2FElCLib%2FElCLib.cxx;h=c16bb6c7dd751405d52fd63d707e6aa5bcb5c933;hb=c5b89fa358ab0932d7edb54af82b86bb4164dd5c;hpb=e7174545ebf9d1a106b72b245258b4ffa5780f82 diff --git a/src/ElCLib/ElCLib.cxx b/src/ElCLib/ElCLib.cxx index 8801ef8a3b..c16bb6c7dd 100644 --- a/src/ElCLib/ElCLib.cxx +++ b/src/ElCLib/ElCLib.cxx @@ -1312,8 +1312,10 @@ Standard_Real ElCLib::LineParameter (const gp_Ax1& L, const gp_Pnt& P) Standard_Real ElCLib::CircleParameter (const gp_Ax2& Pos, const gp_Pnt& P) { - Standard_Real Teta = (Pos.XDirection()) .AngleWithRef - (gp_Vec (Pos.Location(), P), Pos.Direction()); + gp_Vec aVec(Pos.Location(), P); + Standard_Real Teta = 0.0; + if (aVec.SquareMagnitude() > gp::Resolution()) + Teta = (Pos.XDirection()).AngleWithRef(aVec, Pos.Direction()); if (Teta < -1.e-16) Teta += PIPI; else if (Teta < 0) Teta = 0; return Teta;