Salome HOME
Sources formated according to the codeing standards
[modules/shaper.git] / src / GeomAPI / GeomAPI_Circ2d.cpp
index 78c26d69f12049724139dcf49f75b2f26cedbe5d..65ef9b10786b77808f75544a3097b726e9bfdee9 100644 (file)
 
 #define MY_CIRC2D static_cast<gp_Circ2d*>(myImpl)
 
-static gp_Circ2d* newCirc2d(const double theCenterX, const double theCenterY,
-                            const gp_Dir2d theDir, const double theRadius)
+static gp_Circ2d* newCirc2d(const double theCenterX, const double theCenterY, const gp_Dir2d theDir,
+                            const double theRadius)
 {
   gp_Pnt2d aCenter(theCenterX, theCenterY);
   return new gp_Circ2d(gp_Ax2d(aCenter, theDir), theRadius);
 }
 
 static gp_Circ2d* newCirc2d(const double theCenterX, const double theCenterY,
-                            const double thePointX,   const double thePointY)
+                            const double thePointX, const double thePointY)
 {
   gp_Pnt2d aCenter(theCenterX, theCenterY);
   gp_Pnt2d aPoint(thePointX, thePointY);
@@ -34,35 +34,36 @@ static gp_Circ2d* newCirc2d(const double theCenterX, const double theCenterY,
   double aRadius = aCenter.Distance(aPoint);
 
   if (aCenter.IsEqual(aPoint, Precision::Confusion()))
-      return NULL;
+    return NULL;
 
   gp_Dir2d aDir(theCenterX - thePointX, theCenterY - thePointY);
-  
+
   return newCirc2d(theCenterX, theCenterY, aDir, aRadius);
 }
 
 GeomAPI_Circ2d::GeomAPI_Circ2d(const boost::shared_ptr<GeomAPI_Pnt2d>& theCenter,
                                const boost::shared_ptr<GeomAPI_Pnt2d>& theCirclePoint)
-  : GeomAPI_Interface(newCirc2d(theCenter->x(), theCenter->y(),
-                                theCirclePoint->x(),   theCirclePoint->y()))
-{}
+    : GeomAPI_Interface(
+        newCirc2d(theCenter->x(), theCenter->y(), theCirclePoint->x(), theCirclePoint->y()))
+{
+}
 
 GeomAPI_Circ2d::GeomAPI_Circ2d(const boost::shared_ptr<GeomAPI_Pnt2d>& theCenter,
-                               const boost::shared_ptr<GeomAPI_Dir2d>& theDir,
-                               double theRadius)
- : GeomAPI_Interface(newCirc2d(theCenter->x(), theCenter->y(),
-                               theDir->impl<gp_Dir2d>(), theRadius))
+                               const boost::shared_ptr<GeomAPI_Dir2d>& theDir, double theRadius)
+    : GeomAPI_Interface(
+        newCirc2d(theCenter->x(), theCenter->y(), theDir->impl<gp_Dir2d>(), theRadius))
 {
 
 }
 
-const boost::shared_ptr<GeomAPI_Pnt2d> GeomAPI_Circ2d::project(const boost::shared_ptr<GeomAPI_Pnt2d>& thePoint) const
+const boost::shared_ptr<GeomAPI_Pnt2d> GeomAPI_Circ2d::project(
+    const boost::shared_ptr<GeomAPI_Pnt2d>& thePoint) const
 {
   boost::shared_ptr<GeomAPI_Pnt2d> aResult;
   if (!MY_CIRC2D)
-    return aResult;
+  return aResult;
 
-  Handle(Geom2d_Circle) aCircle = new Geom2d_Circle(MY_CIRC2D->Axis(), MY_CIRC2D->Radius());//(aCirc);
+  Handle(Geom2d_Circle) aCircle = new Geom2d_Circle(MY_CIRC2D->Axis(), MY_CIRC2D->Radius());  //(aCirc);
 
   const gp_Pnt2d& aPoint = thePoint->impl<gp_Pnt2d>();