-// Copyright (C) 2007-2008 CEA/DEN, EDF R&D, OPEN CASCADE
+// Copyright (C) 2007-2011 CEA/DEN, EDF R&D, OPEN CASCADE
//
-// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
-// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
+// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
+// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
//
-// This library is free software; you can redistribute it and/or
-// modify it under the terms of the GNU Lesser General Public
-// License as published by the Free Software Foundation; either
-// version 2.1 of the License.
+// This library is free software; you can redistribute it and/or
+// modify it under the terms of the GNU Lesser General Public
+// License as published by the Free Software Foundation; either
+// version 2.1 of the License.
//
-// This library is distributed in the hope that it will be useful,
-// but WITHOUT ANY WARRANTY; without even the implied warranty of
-// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
-// Lesser General Public License for more details.
+// This library is distributed in the hope that it will be useful,
+// but WITHOUT ANY WARRANTY; without even the implied warranty of
+// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
+// Lesser General Public License for more details.
//
-// You should have received a copy of the GNU Lesser General Public
-// License along with this library; if not, write to the Free Software
-// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
-//
-// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+// You should have received a copy of the GNU Lesser General Public
+// License along with this library; if not, write to the Free Software
+// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
//
+// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
+
// File: GEOMAlgo_WireSplitter.cxx
-// Created:
// Author: Peter KURNEV
-// <pkv@irinox>
-//
+
#include <GEOMAlgo_WireSplitter.ixx>
#include <TColStd_SequenceOfReal.hxx>
Standard_Real ClockWiseAngle(const Standard_Real aAngleIn,
const Standard_Real aAngleOut)
{
- Standard_Real aTwoPi=Standard_PI+Standard_PI;
+ Standard_Real aTwoPi = M_PI+M_PI;
Standard_Real dA, A1, A2, AIn, AOut ;
AIn=aAngleIn;
AOut=AOut-aTwoPi;
}
- A1=AIn+Standard_PI;
+ A1 = AIn + M_PI;
if (A1 >= aTwoPi) {
A1=A1-aTwoPi;
dA=A1-A2;
if (dA <= 0.) {
dA=aTwoPi+dA;
+ //modified by NIZNHY-PKV Thu Feb 17 08:26:39 2011f
+ if (dA <= 1.e-14) {
+ dA=aTwoPi;
+ }
+ //modified by NIZNHY-PKV Thu Feb 17 08:26:42 2011t
}
//xx
- //else if (dA <= 1.e-15) {
else if (dA <= 1.e-14) {
dA=aTwoPi;
}
BOPTools_Tools2D::CurveOnSurface (anEdge, myFace, aC2D,
aFirst, aLast, aToler, Standard_True);
//dt=1.e-7;
- //modified by NIZNHY-PKV Wed Sep 10 14:06:04 2008f
- //dt=Tolerance2D(aV, aGAS);
dt=2.*Tolerance2D(aV, aGAS);
- //modified by NIZNHY-PKV Wed Sep 10 14:06:07 2008t
//
aTX=0.25*(aLast - aFirst);
if(dt > aTX) {
Standard_Real anAngle = aRefDir.Angle(aDir2D);
if (anAngle < 0.)
- anAngle += Standard_PI + Standard_PI;
+ anAngle += M_PI + M_PI;
return anAngle;
}