Salome HOME
Issue #1834: Fix length of lines
authorvsv <vitaly.smetannikov@opencascade.com>
Mon, 7 Nov 2016 15:52:24 +0000 (18:52 +0300)
committervsv <vitaly.smetannikov@opencascade.com>
Mon, 7 Nov 2016 15:52:24 +0000 (18:52 +0300)
31 files changed:
src/GeomAlgoAPI/GeomAlgoAPI_Boolean.cpp
src/GeomAlgoAPI/GeomAlgoAPI_EdgeBuilder.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Exception.h
src/GeomAlgoAPI/GeomAlgoAPI_FaceBuilder.cpp
src/GeomAlgoAPI/GeomAlgoAPI_FaceBuilder.h
src/GeomAlgoAPI/GeomAlgoAPI_Intersection.cpp
src/GeomAlgoAPI/GeomAlgoAPI_MakeShape.cpp
src/GeomAlgoAPI/GeomAlgoAPI_MakeShape.h
src/GeomAlgoAPI/GeomAlgoAPI_MakeShapeList.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Partition.cpp
src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.cpp
src/GeomAlgoAPI/GeomAlgoAPI_PaveFiller.h
src/GeomAlgoAPI/GeomAlgoAPI_Pipe.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Pipe.h
src/GeomAlgoAPI/GeomAlgoAPI_Placement.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Placement.h
src/GeomAlgoAPI/GeomAlgoAPI_PointBuilder.cpp
src/GeomAlgoAPI/GeomAlgoAPI_PointBuilder.h
src/GeomAlgoAPI/GeomAlgoAPI_Prism.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Prism.h
src/GeomAlgoAPI/GeomAlgoAPI_Revolution.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Revolution.h
src/GeomAlgoAPI/GeomAlgoAPI_STEPImport.cpp
src/GeomAlgoAPI/GeomAlgoAPI_Sewing.h
src/GeomAlgoAPI/GeomAlgoAPI_ShapeAPI.cpp
src/GeomAlgoAPI/GeomAlgoAPI_ShapeAPI.h
src/GeomAlgoAPI/GeomAlgoAPI_ShapeBuilder.cpp
src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.cpp
src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.h
src/GeomAlgoAPI/GeomAlgoAPI_SketchBuilder.cpp
src/GeomAlgoAPI/GeomAlgoAPI_WireBuilder.h

index 21458a9ce2ab14459e803371484d2342e0b391c5..d198302d7f13106d1f698f6dd4b404835f0e101e 100644 (file)
@@ -32,14 +32,16 @@ void GeomAlgoAPI_Boolean::build(const ListOfShape& theObjects,
 
   // Getting objects.
   TopTools_ListOfShape anObjects;
-  for(ListOfShape::const_iterator anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++)
+  for(ListOfShape::const_iterator 
+    anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++)
   {
     anObjects.Append((*anObjectsIt)->impl<TopoDS_Shape>());
   }
 
   // Getting tools.
   TopTools_ListOfShape aTools;
-  for(ListOfShape::const_iterator aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++)
+  for(ListOfShape::const_iterator 
+    aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++)
   {
     aTools.Append((*aToolsIt)->impl<TopoDS_Shape>());
   }
index 360f46bd2b850f90febbc136e831fbff247bde36..1f8b01832171df75f38897ad147ed9e16b714fd7 100644 (file)
@@ -36,7 +36,7 @@ std::shared_ptr<GeomAPI_Edge> GeomAlgoAPI_EdgeBuilder::line(
   aRes->setImpl(new TopoDS_Shape(anEdge));
   return aRes;
 }
-std::shared_ptr<GeomAPI_Edge> GeomAlgoAPI_EdgeBuilder::line(                                                            
+std::shared_ptr<GeomAPI_Edge> GeomAlgoAPI_EdgeBuilder::line(
     double theDX, double theDY, double theDZ)
 {
   
index 8bdeaa3f328bbda73dae71880d7715bed0f9c019..790af42b543df0dc8a5d103cc7d6b824e6871ca5 100644 (file)
@@ -1,3 +1,5 @@
+// Copyright (C) 2014-20xx CEA/DEN, EDF R&D
+
 #ifndef GeomAlgoAPI_Exception_H_
 #define GeomAlgoAPI_Exception_H_
 
index 25c0a005ab2151f322556e86b02aa7c77f0e83d2..e0aff60b9769d6c2d104c3a8e0b93a38acc38455 100644 (file)
 #include <TopoDS_Face.hxx>
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(const std::shared_ptr<GeomAPI_Pnt> theCenter,
-                                                                  const std::shared_ptr<GeomAPI_Dir> theNormal,
-                                                                  const double theSize)
+std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(
+  const std::shared_ptr<GeomAPI_Pnt> theCenter,
+  const std::shared_ptr<GeomAPI_Dir> theNormal,
+  const double theSize)
 {
   const gp_Pnt& aCenter = theCenter->impl<gp_Pnt>();
   const gp_Dir& aDir = theNormal->impl<gp_Dir>();
@@ -38,8 +39,9 @@ std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(const std::sha
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(const std::shared_ptr<GeomAPI_Pln> thePlane,
-                                                                  const double theSize)
+std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(
+  const std::shared_ptr<GeomAPI_Pln> thePlane,
+  const double theSize)
 {
   // half of the size in each direction from the center
   BRepBuilderAPI_MakeFace aFaceBuilder(thePlane->impl<gp_Pln>(),
@@ -52,8 +54,9 @@ std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::squareFace(const std::sha
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::planarFace(const std::shared_ptr<GeomAPI_Pnt> theCenter,
-                                                                  const std::shared_ptr<GeomAPI_Dir> theNormal)
+std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::planarFace(
+  const std::shared_ptr<GeomAPI_Pnt> theCenter,
+  const std::shared_ptr<GeomAPI_Dir> theNormal)
 {
   const gp_Pnt& aCenter = theCenter->impl<gp_Pnt>();
   const gp_Dir& aDir = theNormal->impl<gp_Dir>();
@@ -65,9 +68,10 @@ std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::planarFace(const std::sha
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::planarFace(const std::shared_ptr<GeomAPI_Pln> thePlane,
-                                                                  const double theX, const double theY,
-                                                                  const double theWidth, const double theHeight)
+std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_FaceBuilder::planarFace(
+  const std::shared_ptr<GeomAPI_Pln> thePlane,
+  const double theX, const double theY,
+  const double theWidth, const double theHeight)
 {
   double aA, aB, aC, aD;
   thePlane->coefficients(aA, aB, aC, aD);
index 4b65249299e8aa738cdb3388b674da8d89124fdd..23173e50b4d1bd674fa112179295f9e168fa80a5 100644 (file)
@@ -43,13 +43,15 @@ class GEOMALGOAPI_EXPORT GeomAlgoAPI_FaceBuilder
                                                   const double theWidth, const double theHeight);
 
   /// Creates a planar face by three vertices.
-  static std::shared_ptr<GeomAPI_Face> planarFaceByThreeVertices(const std::shared_ptr<GeomAPI_Vertex> theVertex1,
-                                                                 const std::shared_ptr<GeomAPI_Vertex> theVertex2,
-                                                                 const std::shared_ptr<GeomAPI_Vertex> theVertex3);
+  static std::shared_ptr<GeomAPI_Face> planarFaceByThreeVertices(
+                        const std::shared_ptr<GeomAPI_Vertex> theVertex1,
+                        const std::shared_ptr<GeomAPI_Vertex> theVertex2,
+                        const std::shared_ptr<GeomAPI_Vertex> theVertex3);
 
   /// Creates a planar face parallel to theFace and passing through theVertex.
-  static std::shared_ptr<GeomAPI_Face> planarFaceByFaceAndVertex(const std::shared_ptr<GeomAPI_Face> theFace,
-                                                                 const std::shared_ptr<GeomAPI_Vertex> theVertex);
+  static std::shared_ptr<GeomAPI_Face> planarFaceByFaceAndVertex(
+                        const std::shared_ptr<GeomAPI_Face> theFace,
+                        const std::shared_ptr<GeomAPI_Vertex> theVertex);
 };
 
 #endif
index a1b29f5cbf4dc432e323cfc62ee0671651c1f62d..273937e2de2f9fedad49e4e673b6d4539ee7ed1d 100644 (file)
@@ -37,7 +37,8 @@ void GeomAlgoAPI_Intersection::build(const ListOfShape& theObjects,
 
   // Getting objects.
   TopTools_ListOfShape anObjects;
-  for (ListOfShape::const_iterator anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++) {
+  for (ListOfShape::const_iterator 
+    anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++) {
     const TopoDS_Shape& aShape = (*anObjectsIt)->impl<TopoDS_Shape>();
     if(!aShape.IsNull()) {
       anObjects.Append(aShape);
@@ -47,7 +48,8 @@ void GeomAlgoAPI_Intersection::build(const ListOfShape& theObjects,
 
   // Getting tools.
   TopTools_ListOfShape aTools;
-  for (ListOfShape::const_iterator aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++) {
+  for (ListOfShape::const_iterator 
+    aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++) {
     const TopoDS_Shape& aShape = (*aToolsIt)->impl<TopoDS_Shape>();
     if(!aShape.IsNull()) {
       aTools.Append(aShape);
index 14b3bcb3886369a8c31335f3ff2089ef3f25e2a5..28942716421fa41806d5ef60835ebd3ba018c9cc 100644 (file)
@@ -240,7 +240,8 @@ bool GeomAlgoAPI_MakeShape::checkValid(std::string theMessage){
   }
   
   if (aNbVolumes != 1) {
-    myError = theMessage + " :: connexity error, the resulting shape is made of several separate solids."; 
+    myError = theMessage +
+      " :: connexity error, the resulting shape is made of several separate solids.";
     return false;
   }
   
index 6fc03c6f8683246ddfdfac6a95786288d024fa66..649684ee05dd479c9870972d80b876c519171401 100644 (file)
@@ -37,7 +37,8 @@ public:
   /// \brief Constructor by builder and builder type.
   /// \param[in] theBuilder pointer to the builder.
   /// \param[in] theBuilderType builder type.
-  template<class T> explicit GeomAlgoAPI_MakeShape(T* theBuilder, const BuilderType theBuilderType = OCCT_BRepBuilderAPI_MakeShape)
+  template<class T> explicit GeomAlgoAPI_MakeShape(T* theBuilder, 
+    const BuilderType theBuilderType = OCCT_BRepBuilderAPI_MakeShape)
   : GeomAPI_Interface(theBuilder),
     myBuilderType(theBuilderType)
   {
@@ -47,7 +48,8 @@ public:
   /// \brief Initializes internals.
   /// \param[in] theBuilder pointer to the builder.
   /// \param[in] theBuilderType builder type.
-  template<class T> void initialize(T* theBuilder, const BuilderType theBuilderType = OCCT_BRepBuilderAPI_MakeShape)
+  template<class T> void initialize(T* theBuilder, 
+    const BuilderType theBuilderType = OCCT_BRepBuilderAPI_MakeShape)
   {
     setImpl(theBuilder);
     myBuilderType = theBuilderType;
@@ -89,7 +91,8 @@ public:
   GEOMALGOAPI_EXPORT virtual bool check() { return true; };
 
   ///  \return the list of created faces.
-  GEOMALGOAPI_EXPORT std::map< std::string, std::shared_ptr<GeomAPI_Shape> > getCreatedFaces() {return myCreatedFaces;}
+  GEOMALGOAPI_EXPORT std::map< std::string, std::shared_ptr<GeomAPI_Shape> > getCreatedFaces()
+  {return myCreatedFaces;}
 
   /// \return the error.
   GEOMALGOAPI_EXPORT std::string getError() { return myError; }
@@ -114,9 +117,12 @@ protected:
   void setShape(const std::shared_ptr<GeomAPI_Shape> theShape);
 
 protected:
-  std::shared_ptr<GeomAPI_DataMapOfShapeShape> myMap; ///< Data map to keep correct orientation of sub-shapes.
-  std::string myError; /// Error occurred during the execution of an algorithm.
-  std::map< std::string, std::shared_ptr<GeomAPI_Shape> > myCreatedFaces; /// Map of created faces with their name for naming.
+   /// Data map to keep correct orientation of sub-shapes.
+  std::shared_ptr<GeomAPI_DataMapOfShapeShape> myMap;
+  /// Error occurred during the execution of an algorithm.
+  std::string myError;
+  /// Map of created faces with their name for naming.
+  std::map< std::string, std::shared_ptr<GeomAPI_Shape> > myCreatedFaces; 
   
 private:
   /// \brief Initializes internals.
index 3c00ea2051c5dec5380f6dfd86afdd430993d24e..86a01cf6a75482fed36edf2d8a2704837521b178 100644 (file)
@@ -41,7 +41,8 @@ void GeomAlgoAPI_MakeShapeList::init(const ListOfMakeShape& theMakeShapeList)
 }
 
 //=================================================================================================
-void GeomAlgoAPI_MakeShapeList::appendAlgo(const std::shared_ptr<GeomAlgoAPI_MakeShape> theMakeShape)
+void GeomAlgoAPI_MakeShapeList::appendAlgo(
+  const std::shared_ptr<GeomAlgoAPI_MakeShape> theMakeShape)
 {
   myListOfMakeShape.push_back(theMakeShape);
   if(!myMap.get()) {
@@ -78,7 +79,8 @@ void GeomAlgoAPI_MakeShapeList::modified(const std::shared_ptr<GeomAPI_Shape> th
 
 bool GeomAlgoAPI_MakeShapeList::isDeleted(const std::shared_ptr<GeomAPI_Shape> theShape)
 {
-  for(ListOfMakeShape::iterator aBuilderIt = myListOfMakeShape.begin(); aBuilderIt != myListOfMakeShape.end(); aBuilderIt++) {
+  for(ListOfMakeShape::iterator aBuilderIt = myListOfMakeShape.begin(); 
+      aBuilderIt != myListOfMakeShape.end(); aBuilderIt++) {
     std::shared_ptr<GeomAlgoAPI_MakeShape> aMakeShape = *aBuilderIt;
     if(aMakeShape->isDeleted(theShape)) {
       return true;
@@ -103,16 +105,19 @@ void GeomAlgoAPI_MakeShapeList::result(const std::shared_ptr<GeomAPI_Shape> theS
   aResultShapesMap.Add(theShape->impl<TopoDS_Shape>());
   aResultShapesList.Append(theShape->impl<TopoDS_Shape>());
 
-  for(ListOfMakeShape::iterator aBuilderIt = myListOfMakeShape.begin(); aBuilderIt != myListOfMakeShape.end(); aBuilderIt++) {
+  for(ListOfMakeShape::iterator aBuilderIt = myListOfMakeShape.begin(); 
+      aBuilderIt != myListOfMakeShape.end(); aBuilderIt++) {
     std::shared_ptr<GeomAlgoAPI_MakeShape> aMakeShape = *aBuilderIt;
     NCollection_Map<TopoDS_Shape> aTempShapes;
     bool hasResults = false;
-    for(NCollection_Map<TopoDS_Shape>::Iterator aShapeIt(anAlgoShapes); aShapeIt.More(); aShapeIt.Next()) {
+    for(NCollection_Map<TopoDS_Shape>::Iterator
+        aShapeIt(anAlgoShapes); aShapeIt.More(); aShapeIt.Next()) {
       std::shared_ptr<GeomAPI_Shape> aShape(new GeomAPI_Shape);
       aShape->setImpl(new TopoDS_Shape(aShapeIt.Value()));
       ListOfShape aGeneratedShapes;
       aMakeShape->generated(aShape, aGeneratedShapes);
-      for(ListOfShape::const_iterator anIt = aGeneratedShapes.cbegin(); anIt != aGeneratedShapes.cend(); anIt++) {
+      for(ListOfShape::const_iterator
+          anIt = aGeneratedShapes.cbegin(); anIt != aGeneratedShapes.cend(); anIt++) {
         const TopoDS_Shape& anItShape = (*anIt)->impl<TopoDS_Shape>();
         aTempShapes.Add(anItShape);
         if(aResultShapesMap.Add(anItShape) == Standard_True) {
@@ -122,7 +127,8 @@ void GeomAlgoAPI_MakeShapeList::result(const std::shared_ptr<GeomAPI_Shape> theS
       }
       ListOfShape aModifiedShapes;
       aMakeShape->modified(aShape, aModifiedShapes);
-      for(ListOfShape::const_iterator anIt = aModifiedShapes.cbegin(); anIt != aModifiedShapes.cend(); anIt++) {
+      for(ListOfShape::const_iterator 
+          anIt = aModifiedShapes.cbegin(); anIt != aModifiedShapes.cend(); anIt++) {
         const TopoDS_Shape& anItShape = (*anIt)->impl<TopoDS_Shape>();
         aTempShapes.Add(anItShape);
         if(aResultShapesMap.Add(anItShape) == Standard_True) {
@@ -133,7 +139,8 @@ void GeomAlgoAPI_MakeShapeList::result(const std::shared_ptr<GeomAPI_Shape> theS
       if(hasResults) {
         const TopoDS_Shape& aTopoDSShape = aShapeIt.Value();
         if(aResultShapesMap.Remove(aTopoDSShape) == Standard_True) {
-          for(NCollection_List<TopoDS_Shape>::Iterator aResIt(aResultShapesList); aResIt.More(); aResIt.Next()) {
+          for(NCollection_List<TopoDS_Shape>::Iterator 
+              aResIt(aResultShapesList); aResIt.More(); aResIt.Next()) {
             if(aTopoDSShape.IsEqual(aResIt.Value())) {
               aResultShapesList.Remove(aResIt);
               break;
@@ -145,7 +152,8 @@ void GeomAlgoAPI_MakeShapeList::result(const std::shared_ptr<GeomAPI_Shape> theS
     anAlgoShapes.Unite(aTempShapes);
   }
 
-  for(NCollection_List<TopoDS_Shape>::Iterator aShapeIt(aResultShapesList); aShapeIt.More(); aShapeIt.Next()) {
+  for(NCollection_List<TopoDS_Shape>::Iterator 
+      aShapeIt(aResultShapesList); aShapeIt.More(); aShapeIt.Next()) {
     std::shared_ptr<GeomAPI_Shape> aShape(new GeomAPI_Shape());
     aShape->setImpl(new TopoDS_Shape(aShapeIt.Value()));
     theHistory.push_back(aShape);
index 06849b9f17eb42f2debdbb3f7297a674e339b9a8..a19419b7394b4fdfb7c6c4af884ac0a2bcb68a91 100644 (file)
@@ -47,13 +47,15 @@ void GeomAlgoAPI_Partition::build(const ListOfShape& theObjects,
   this->setBuilderType(OCCT_BOPAlgo_Builder);
 
   // Getting objects.
-  for (ListOfShape::const_iterator anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++) {
+  for (ListOfShape::const_iterator 
+       anObjectsIt = theObjects.begin(); anObjectsIt != theObjects.end(); anObjectsIt++) {
     const TopoDS_Shape& aShape = (*anObjectsIt)->impl<TopoDS_Shape>();
     anOperation->AddArgument(aShape);
   }
 
   // Getting tools.
-  for (ListOfShape::const_iterator aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++) {
+  for (ListOfShape::const_iterator 
+       aToolsIt = theTools.begin(); aToolsIt != theTools.end(); aToolsIt++) {
     const TopoDS_Shape& aShape = (*aToolsIt)->impl<TopoDS_Shape>();
     anOperation->AddTool(aShape);
   }
index 6f9d183aa051b982da4108e6d5c6ff1619bc5d95..76df6cbb93dc0510e0c8fec5f3840d37afce968b 100644 (file)
 #include <TopoDS_Iterator.hxx>
 
 //=================================================================================================
-GeomAlgoAPI_PaveFiller::GeomAlgoAPI_PaveFiller(const ListOfShape& theListOfShape, const bool theIsMakeCompSolids)
+GeomAlgoAPI_PaveFiller::GeomAlgoAPI_PaveFiller(const ListOfShape& theListOfShape, 
+                                               const bool theIsMakeCompSolids)
 {
   build(theListOfShape, theIsMakeCompSolids);
 }
 
 
 //=================================================================================================
-void GeomAlgoAPI_PaveFiller::build(const ListOfShape& theListOfShape, const bool theIsMakeCompSolids)
+void GeomAlgoAPI_PaveFiller::build(const ListOfShape& theListOfShape,
+                                   const bool theIsMakeCompSolids)
 {
   BOPAlgo_PaveFiller aPaveFiller;
   BOPCol_ListOfShape aListOfShape;
-  for(ListOfShape::const_iterator anIt = theListOfShape.cbegin(); anIt != theListOfShape.cend(); anIt++) {
+  for(ListOfShape::const_iterator 
+    anIt = theListOfShape.cbegin(); anIt != theListOfShape.cend(); anIt++) {
     const TopoDS_Shape& aShape = (*anIt)->impl<TopoDS_Shape>();
     if(aShape.ShapeType() == TopAbs_COMPOUND) {
       for(TopoDS_Iterator anIter(aShape); anIter.More(); anIter.Next()) {
index d14aacbacba5d184f8de74a54406fd0bceb09b3a..5a63fbf5e4d67a1eb61747e2d275d7950d9fa21a 100644 (file)
 
 /// \class GeomAlgoAPI_PaveFiller
 /// \ingroup DataAlgo
-/// \brief Finds the common parts from the list of shapes and breaks it to shapes with shared subshapes.
+/// \brief Finds the common parts from the list of shapes and 
+///  breaks it to shapes with shared subshapes.
 class GeomAlgoAPI_PaveFiller : public GeomAlgoAPI_MakeShape
 {
 public:
   /// \brief Constructor.
   /// \param[in] theListOfShape list of shape which should be splitted.
   /// \param[in] theIsMakeCompSolids if true gather shapes with shared faces to compsolids.
-  GEOMALGOAPI_EXPORT GeomAlgoAPI_PaveFiller(const ListOfShape& theListOfShape, const bool theIsMakeCompSolids = false);
+  GEOMALGOAPI_EXPORT GeomAlgoAPI_PaveFiller(const ListOfShape& theListOfShape, 
+                                            const bool theIsMakeCompSolids = false);
 
 private:
   /// Builds resulting shape.
index 04b310006af1f7ef84c917153b5fdece5c2b2bfb..ca7b81140cf61a90f799688251e681f6af628c46 100644 (file)
@@ -183,7 +183,8 @@ void GeomAlgoAPI_Pipe::build(const ListOfShape& theBaseShapes,
                              const ListOfShape& theLocations,
                              const GeomShapePtr thePathShape)
 {
-  if(theBaseShapes.empty() || (!theLocations.empty() && theLocations.size() != theBaseShapes.size())) {
+  if(theBaseShapes.empty() || 
+     (!theLocations.empty() && theLocations.size() != theBaseShapes.size())) {
     return;
   }
 
index 8c7113b2a307b6049cd04e0648d23b790e016775..fb0f0b6c0aa3e3aa17ed62c7c0f42bf232dffec2 100644 (file)
@@ -15,7 +15,8 @@
 
 /// \class GeomAlgoAPI_Pipe
 /// \ingroup DataAlgo
-/// \brief Allows to create extrusion of objects along a path. It produces the following results from objects:\n
+/// \brief Allows to create extrusion of objects along a path. 
+/// It produces the following results from objects:\n
 /// Vertex -> Edge\n
 /// Edge -> Face\n
 /// Wire -> Shell\n
index de553626b2b98896807157e28af35e95041ea32c..af06ddd819a1d2374fc20b96c893ec1e38845e06 100644 (file)
@@ -117,10 +117,12 @@ void GeomAlgoAPI_Placement::build(const std::shared_ptr<GeomAPI_Shape>& theSourc
       if (hasDirection[0] || hasDirection[1]) { // plane - line
         int anInd = hasDirection[0] ? 0 : 1;
         gp_Vec aVec = aSrcDstNormals[1 - anInd].Crossed(aSrcDstDirections[anInd]);
-        if (aVec.SquareMagnitude() < Precision::SquareConfusion()) { // normal and direction are collinear
+        if (aVec.SquareMagnitude() < Precision::SquareConfusion()) {
+          // normal and direction are collinear
           aVec = aSrcDstNormals[1 - anInd].Crossed(
             gp_Vec(aSrcDstPoints[1 - anInd], aSrcDstPoints[anInd]));
-          if (aVec.SquareMagnitude() < Precision::SquareConfusion()) { // normal and points direction are collinear
+          if (aVec.SquareMagnitude() < Precision::SquareConfusion()) {
+            // normal and points direction are collinear
             if (Abs(aSrcDstNormals[1 - anInd].Y()) >= Precision::Confusion() || 
               Abs(aSrcDstNormals[1 - anInd].Z()) >= Precision::Confusion())
               aVec = gp::DX();
@@ -196,7 +198,6 @@ void GeomAlgoAPI_Placement::build(const std::shared_ptr<GeomAPI_Shape>& theSourc
   if (theSimpleTransform) { // just add transformation
     TopLoc_Location aDelta(aTrsf);
     // store the accumulated information about the result and this delta
-    //myTrsf = std::shared_ptr<GeomAPI_Trsf>(new GeomAPI_Trsf(new gp_Trsf(aTrsf * aSourceShape.Location().Transformation())));
     myTrsf.reset(new GeomAPI_Trsf(new gp_Trsf(aTrsf)));
     TopoDS_Shape aResult = aSourceShape.Moved(aDelta);
     std::shared_ptr<GeomAPI_Shape> aShape(new GeomAPI_Shape());
index 7fa31bcd55e2c40c5c0396f45f07b47b380c33a4..b152493407358d6a8bef757568e91c912697c488 100644 (file)
@@ -25,9 +25,11 @@ public:
   /// \param[in] theDestSolid    invariant shape
   /// \param[in] theSourceShape  a shape on the solid to be made coincident with destination object
   /// \param[in] theDestShape    destination object
-  /// \param[in] theIsReverse    indicates that the solid materials should be on the same side against the destination plane
+  /// \param[in] theIsReverse    indicates that the solid materials should be on the same side 
+  ///                            against the destination plane
   /// \param[in] theIsCentering  indicates the planes should be centered
-  /// \param[in] theSimpleTransform makes just transformation of shape without changing of topology or geometry
+  /// \param[in] theSimpleTransform makes just transformation of shape 
+  ///                               without changing of topology or geometry
   GEOMALGOAPI_EXPORT GeomAlgoAPI_Placement(const std::shared_ptr<GeomAPI_Shape> theSourceSolid,
                                            const std::shared_ptr<GeomAPI_Shape> theDestSolid,
                                            const std::shared_ptr<GeomAPI_Shape> theSourceShape,
index e7414346d08c7f64a1aa29025c088ba04a39a8e0..69cdabbfd501378ff9c9bbd728fc5f9f6abcb1a3 100644 (file)
@@ -26,7 +26,8 @@
 #include <TopoDS_Vertex.hxx>
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Vertex> GeomAlgoAPI_PointBuilder::vertex(const std::shared_ptr<GeomAPI_Pnt> thePoint)
+std::shared_ptr<GeomAPI_Vertex> 
+  GeomAlgoAPI_PointBuilder::vertex(const std::shared_ptr<GeomAPI_Pnt> thePoint)
 {
   const gp_Pnt& aPnt = thePoint->impl<gp_Pnt>();
   BRepBuilderAPI_MakeVertex aMaker(aPnt);
@@ -50,7 +51,8 @@ std::shared_ptr<GeomAPI_Vertex> GeomAlgoAPI_PointBuilder::vertex(const double th
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Pnt> GeomAlgoAPI_PointBuilder::point(const std::shared_ptr<GeomAPI_Shape> theVertex)
+std::shared_ptr<GeomAPI_Pnt> 
+  GeomAlgoAPI_PointBuilder::point(const std::shared_ptr<GeomAPI_Shape> theVertex)
 {
   TopoDS_Shape aShape = theVertex->impl<TopoDS_Shape>();
   if ((!aShape.IsNull()) && (aShape.ShapeType() == TopAbs_VERTEX)) {
@@ -63,10 +65,11 @@ std::shared_ptr<GeomAPI_Pnt> GeomAlgoAPI_PointBuilder::point(const std::shared_p
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Vertex> GeomAlgoAPI_PointBuilder::vertexOnEdge(const std::shared_ptr<GeomAPI_Edge> theEdge,
-                                                                       const double theValue,
-                                                                       const bool theIsPercent,
-                                                                       const bool theIsReverse)
+std::shared_ptr<GeomAPI_Vertex> GeomAlgoAPI_PointBuilder::vertexOnEdge(
+                                            const std::shared_ptr<GeomAPI_Edge> theEdge,
+                                            const double theValue,
+                                            const bool theIsPercent,
+                                            const bool theIsReverse)
 {
   std::shared_ptr<GeomAPI_Vertex> aVertex;
 
index 28703d91da9a85132f5277f91308e411b9661da4..be219a503065c4ae09230352493c8d6c48cc7bc8 100644 (file)
@@ -33,7 +33,8 @@ public:
   /// \brief Creates vertex by edge and distance on it.
   /// \param[in] theEdge edge.
   /// \param[in] theValue distance value.
-  /// \param[in] theIsPercent if true theValue will be treated as a percentage of theEdge total length.
+  /// \param[in] theIsPercent if true theValue will be treated 
+  ///                         as a percentage of theEdge total length.
   /// \param[in] theIsReverse if true the distance will be measured from the edge end point.
   /// \return created vertex.
   static std::shared_ptr<GeomAPI_Vertex> vertexOnEdge(const std::shared_ptr<GeomAPI_Edge> theEdge,
@@ -45,22 +46,25 @@ public:
   /// \param[in] theVertex vertex to project.
   /// \param[in] thePlane face for projection. Should be planar.
   /// \return created vertex.
-  static std::shared_ptr<GeomAPI_Vertex> vertexByProjection(const std::shared_ptr<GeomAPI_Vertex> theVertex,
-                                                            const std::shared_ptr<GeomAPI_Face> thePlane);
+  static std::shared_ptr<GeomAPI_Vertex>
+    vertexByProjection(const std::shared_ptr<GeomAPI_Vertex> theVertex,
+                       const std::shared_ptr<GeomAPI_Face> thePlane);
 
   /// \brief Creates vertex by intersection two coplanar lines.
   /// \param[in] theEdge1 first linear edge.
   /// \param[in] theEdge2 second linear edge.
   /// \return created vertex.
-  static std::shared_ptr<GeomAPI_Vertex> vertexByIntersection(const std::shared_ptr<GeomAPI_Edge> theEdge1,
-                                                              const std::shared_ptr<GeomAPI_Edge> theEdge2);
+  static std::shared_ptr<GeomAPI_Vertex>
+    vertexByIntersection(const std::shared_ptr<GeomAPI_Edge> theEdge1,
+                         const std::shared_ptr<GeomAPI_Edge> theEdge2);
 
   /// \brief Creates vertex by intersection line and plane.
   /// \param[in] theEdge linear edge.
   /// \param[in] theFace planar face.
   /// \return created vertex.
-  static std::shared_ptr<GeomAPI_Vertex> vertexByIntersection(const std::shared_ptr<GeomAPI_Edge> theEdge,
-                                                              const std::shared_ptr<GeomAPI_Face> theFace);
+  static std::shared_ptr<GeomAPI_Vertex> 
+    vertexByIntersection(const std::shared_ptr<GeomAPI_Edge> theEdge,
+                         const std::shared_ptr<GeomAPI_Face> theFace);
 
   /// Return point by shape vertex
   static std::shared_ptr<GeomAPI_Pnt> point(const std::shared_ptr<GeomAPI_Shape> theVertex);
index 49204ee9032404f5fc90e19786ca27e61c2f2617..acc94d25f49ffdebd396b10a5a46d8dee5225667 100644 (file)
@@ -57,7 +57,8 @@ GeomAlgoAPI_Prism::GeomAlgoAPI_Prism(const GeomShapePtr theBaseShape,
                                      const double       theToSize,
                                      const double       theFromSize)
 {
-  build(theBaseShape, std::shared_ptr<GeomAPI_Dir>(), GeomShapePtr(), theToSize, GeomShapePtr(), theFromSize);
+  build(theBaseShape, std::shared_ptr<GeomAPI_Dir>(), GeomShapePtr(),
+    theToSize, GeomShapePtr(), theFromSize);
 }
 
 //==================================================================================================
@@ -76,7 +77,8 @@ GeomAlgoAPI_Prism::GeomAlgoAPI_Prism(const GeomShapePtr theBaseShape,
                                      const GeomShapePtr theFromShape,
                                      const double       theFromSize)
 {
-  build(theBaseShape, std::shared_ptr<GeomAPI_Dir>(), theToShape, theToSize, theFromShape, theFromSize);
+  build(theBaseShape, std::shared_ptr<GeomAPI_Dir>(), theToShape, 
+        theToSize, theFromShape, theFromSize);
 }
 
 //==================================================================================================
@@ -99,7 +101,8 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
                               const double                       theFromSize)
 {
   if(!theBaseShape.get() ||
-    (((!theFromShape.get() && !theToShape.get()) || (theFromShape.get() && theToShape.get() && theFromShape->isEqual(theToShape)))
+    (((!theFromShape.get() && !theToShape.get()) || 
+    (theFromShape.get() && theToShape.get() && theFromShape->isEqual(theToShape)))
     && (theFromSize == -theToSize))) {
     return;
   }
@@ -187,22 +190,26 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
     // Moving base shape.
     gp_Trsf aTrsf;
     aTrsf.SetTranslation(aDirVec * -theFromSize);
-    BRepBuilderAPI_Transform* aTransformBuilder = new BRepBuilderAPI_Transform(aBaseShape, aTrsf);
+    BRepBuilderAPI_Transform* aTransformBuilder = 
+      new BRepBuilderAPI_Transform(aBaseShape, aTrsf);
     if(!aTransformBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aTransformBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aTransformBuilder)));
     if(!aTransformBuilder->IsDone()) {
       return;
     }
     TopoDS_Shape aMovedBase = aTransformBuilder->Shape();
 
     // Making prism.
-    BRepPrimAPI_MakePrism* aPrismBuilder = new BRepPrimAPI_MakePrism(aMovedBase, aDirVec * (theFromSize + theToSize));
+    BRepPrimAPI_MakePrism* aPrismBuilder = 
+      new BRepPrimAPI_MakePrism(aMovedBase, aDirVec * (theFromSize + theToSize));
     if(!aPrismBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aPrismBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aPrismBuilder)));
     if(!aPrismBuilder->IsDone()) {
       return;
     }
@@ -230,12 +237,14 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
 
     bool aSign = aFromLoc->xyz()->dot(aBaseDir->xyz()) > aToLoc->xyz()->dot(aBaseDir->xyz());
 
-    std::shared_ptr<GeomAPI_Pnt> aFromPnt(new GeomAPI_Pnt(aFromLoc->xyz()->added(aBaseDir->xyz()->multiplied(
-                                                          aSign ? theFromSize : -theFromSize))));
+    std::shared_ptr<GeomAPI_Pnt> aFromPnt(
+      new GeomAPI_Pnt(aFromLoc->xyz()->added(aBaseDir->xyz()->multiplied(
+                      aSign ? theFromSize : -theFromSize))));
     aBoundingFromShape = GeomAlgoAPI_FaceBuilder::planarFace(aFromPnt, aFromDir);
 
-    std::shared_ptr<GeomAPI_Pnt> aToPnt(new GeomAPI_Pnt(aToLoc->xyz()->added(aBaseDir->xyz()->multiplied(
-                                                        aSign ? -theToSize : theToSize))));
+    std::shared_ptr<GeomAPI_Pnt> aToPnt(
+      new GeomAPI_Pnt(aToLoc->xyz()->added(aBaseDir->xyz()->multiplied(
+                      aSign ? -theToSize : theToSize))));
     aBoundingToShape = GeomAlgoAPI_FaceBuilder::planarFace(aToPnt, aToDir);
 
     // Getting bounding box for base shape.
@@ -286,18 +295,21 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
     if(!aTransformBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aTransformBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aTransformBuilder)));
     if(!aTransformBuilder->IsDone()) {
       return;
     }
     TopoDS_Shape aMovedBase = aTransformBuilder->Shape();
 
     // Making prism.
-    BRepPrimAPI_MakePrism* aPrismBuilder = new BRepPrimAPI_MakePrism(aMovedBase, aDirVec * 2 * aPrismLength);
+    BRepPrimAPI_MakePrism* aPrismBuilder = 
+      new BRepPrimAPI_MakePrism(aMovedBase, aDirVec * 2 * aPrismLength);
     if(!aPrismBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aPrismBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aPrismBuilder)));
     if(!aPrismBuilder->IsDone()) {
       return;
     }
@@ -358,7 +370,8 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
     if(!aToCutBuilder->IsDone()) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aToCutBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aToCutBuilder)));
     aResult = aToCutBuilder->Shape();
     if(aResult.ShapeType() == TopAbs_COMPOUND) {
       aResult = GeomAlgoAPI_DFLoader::refineResult(aResult);
@@ -378,7 +391,8 @@ void GeomAlgoAPI_Prism::build(const GeomShapePtr&                theBaseShape,
     if(!aFromCutBuilder->IsDone()) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aFromCutBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aFromCutBuilder)));
     aResult = aFromCutBuilder->Shape();
     TopoDS_Iterator aCheckIt(aResult);
     if(!aCheckIt.More()) {
@@ -457,11 +471,13 @@ void storeGenerationHistory(GeomAlgoAPI_Prism* thePrismAlgo,
     if(theType == TopAbs_VERTEX) {
       gp_Pnt aPnt = BRep_Tool::Pnt(TopoDS::Vertex(aShape));
       IntTools_Context anIntTools;
-      if(anIntTools.IsValidPointForFace(aPnt, theToFace, Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, 
+          theToFace, Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
         thePrismAlgo->addToShape(aGeomSh);
       }
-      if(anIntTools.IsValidPointForFace(aPnt, theFromFace, Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, 
+          theFromFace, Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
         thePrismAlgo->addFromShape(aGeomSh);
       }
index be17e8b7ad7d843195b2b9bddce00f42fb6fe069..af7f4501b620c25d24898a65fc96c11521c64058 100644 (file)
@@ -34,7 +34,8 @@ public:
 
   /// \brief Creates extrusion for the given shape along the normal for this shape.
   /// \param[in] theBaseShape vertex, edge, wire, face or shell.
-  /// \param[in] theDirection direction of extrusion. Can be empty if theBaseShape is planar wire or face.
+  /// \param[in] theDirection direction of extrusion. 
+  ///                         Can be empty if theBaseShape is planar wire or face.
   /// \param[in] theToSize offset for "to" plane.
   /// \param[in] theFromSize offset for "from" plane.
   GEOMALGOAPI_EXPORT GeomAlgoAPI_Prism(const GeomShapePtr                 theBaseShape,
@@ -44,9 +45,11 @@ public:
 
   /// \brief Creates extrusion for the given shape along the normal for this shape.
   /// \param[in] theBaseShape planar face or wire to be extruded.
-  /// \param[in] theToShape top bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theToShape top bounding shape. Can be empty. 
+  ///                       In this case offset will be applied to the basis.
   /// \param[in] theToSize offset for "to" plane.
-  /// \param[in] theFromShape bottom bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theFromShape bottom bounding shape. Can be empty. 
+  ///                         In this case offset will be applied to the basis.
   /// \param[in] theFromSize offset for "from" plane.
   GEOMALGOAPI_EXPORT GeomAlgoAPI_Prism(const GeomShapePtr theBaseShape,
                                        const GeomShapePtr theToShape,
@@ -56,10 +59,13 @@ public:
 
   /// \brief Creates extrusion for the given shape along the normal for this shape.
   /// \param[in] theBaseShape planar face or wire to be extruded.
-  /// \param[in] theDirection direction of extrusion. Can be empty if theBaseShape is planar wire or face.
-  /// \param[in] theToShape top bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theDirection direction of extrusion. 
+  ///                         Can be empty if theBaseShape is planar wire or face.
+  /// \param[in] theToShape top bounding shape. Can be empty.
+  ///                       In this case offset will be applied to the basis.
   /// \param[in] theToSize offset for "to" plane.
-  /// \param[in] theFromShape bottom bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theFromShape bottom bounding shape. Can be empty.
+  ///                         In this case offset will be applied to the basis.
   /// \param[in] theFromSize offset for "from" plane.
   GEOMALGOAPI_EXPORT GeomAlgoAPI_Prism(const GeomShapePtr                 theBaseShape,
                                        const std::shared_ptr<GeomAPI_Dir> theDirection,
index 9ff572fb464e93a4abd85ba5b3b90c13bea4bcfe..82c9b6ab46cad369c68f421a42a261b8c32225e6 100644 (file)
@@ -104,7 +104,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
                                    const double                        theFromAngle)
 {
   if(!theBaseShape || !theAxis ||
-    (((!theFromShape && !theToShape) || (theFromShape && theToShape && theFromShape->isEqual(theToShape)))
+    (((!theFromShape && !theToShape) || 
+    (theFromShape && theToShape && theFromShape->isEqual(theToShape)))
     && (theFromAngle == -theToAngle))) {
     return;
   }
@@ -188,7 +189,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     if(!aBaseTransform) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aBaseTransform)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aBaseTransform)));
     if(!aBaseTransform->IsDone()) {
       return;
     }
@@ -196,13 +198,14 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
 
     // Making revolution to the angle equal to the sum of "from angle" and "to angle".
     BRepPrimAPI_MakeRevol* aRevolBuilder = new BRepPrimAPI_MakeRevol(aRotatedBase,
-                                                                      anAxis,
-                                                                      (theFromAngle + theToAngle) / 180 * M_PI,
-                                                                      Standard_True);
+                                                        anAxis,
+                                                        (theFromAngle + theToAngle) / 180 * M_PI,
+                                                        Standard_True);
     if(!aRevolBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aRevolBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aRevolBuilder)));
     if(!aRevolBuilder->IsDone()) {
       return;
     }
@@ -217,11 +220,13 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     }
   } else if(theFromShape && theToShape) { // Case 2: When both bounding planes were set.
     // Making revolution to the 360 angle.
-    BRepPrimAPI_MakeRevol* aRevolBuilder = new BRepPrimAPI_MakeRevol(aBaseShape, anAxis, 2 * M_PI, Standard_True);
+    BRepPrimAPI_MakeRevol* aRevolBuilder = 
+      new BRepPrimAPI_MakeRevol(aBaseShape, anAxis, 2 * M_PI, Standard_True);
     if(!aRevolBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aRevolBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aRevolBuilder)));
     if(!aRevolBuilder->IsDone()) {
       return;
     }
@@ -234,7 +239,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     // Getting planes from bounding face.
     GeomLib_IsPlanarSurface isFromPlanar(BRep_Tool::Surface(aFromFace));
     GeomLib_IsPlanarSurface isToPlanar(BRep_Tool::Surface(aToFace));
-    if(!isFromPlanar.IsPlanar() || !isToPlanar.IsPlanar()) {// non-planar shapes is not supported for revolution bounding
+    if(!isFromPlanar.IsPlanar() || !isToPlanar.IsPlanar()) {
+      // non-planar shapes is not supported for revolution bounding
       return;
     }
 
@@ -256,8 +262,12 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     // Rotating bounding planes to the specified angle.
     gp_Trsf aFromTrsf;
     gp_Trsf aToTrsf;
-    double aFromRotAngle = ((aFromPln.Axis().Direction() * aBasePlane->Axis().Direction()) > 0) ? -theFromAngle : theFromAngle;
-    double aToRotAngle = ((aToPln.Axis().Direction() * aBasePlane->Axis().Direction()) > 0) ? -theToAngle : theToAngle;
+    double aFromRotAngle = 
+      ((aFromPln.Axis().Direction() * aBasePlane->Axis().Direction()) > 0) ? -theFromAngle : 
+                                                                              theFromAngle;
+    double aToRotAngle = 
+      ((aToPln.Axis().Direction() * aBasePlane->Axis().Direction()) > 0) ? -theToAngle :
+                                                                            theToAngle;
     aFromTrsf.SetRotation(anAxis,aFromRotAngle / 180.0 * M_PI);
     aToTrsf.SetRotation(anAxis, aToRotAngle / 180.0 * M_PI);
     BRepBuilderAPI_Transform aFromTransform(aFromSolid, aFromTrsf, true);
@@ -273,7 +283,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     if(!aFromCutBuilder->IsDone()) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aFromCutBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aFromCutBuilder)));
     aResult = aFromCutBuilder->Shape();
     if(aResult.ShapeType() == TopAbs_COMPOUND) {
       aResult = GeomAlgoAPI_DFLoader::refineResult(aResult);
@@ -285,7 +296,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     if(!aToCutBuilder->IsDone()) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aToCutBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aToCutBuilder)));
     aResult = aToCutBuilder->Shape();
     TopoDS_Iterator aCheckIt(aResult);
     if(!aCheckIt.More()) {
@@ -305,7 +317,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
       aResult = aGeomShape->impl<TopoDS_Shape>();
     }
 
-    // If after cut we got more than one solids then take closest to the center of mass of the base face.
+    // If after cut we got more than one solids then take closest 
+    // to the center of mass of the base face.
     aResult = findClosest(aResult, aBaseCentre);
 
     // Setting naming.
@@ -317,11 +330,13 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     }
   } else { //Case 3: When only one bounding plane was set.
     // Making revolution to the 360 angle.
-    BRepPrimAPI_MakeRevol* aRevolBuilder = new BRepPrimAPI_MakeRevol(aBaseShape, anAxis, 2 * M_PI, Standard_True);
+    BRepPrimAPI_MakeRevol* aRevolBuilder = 
+      new BRepPrimAPI_MakeRevol(aBaseShape, anAxis, 2 * M_PI, Standard_True);
     if(!aRevolBuilder) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aRevolBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aRevolBuilder)));
     if(!aRevolBuilder->IsDone()) {
       return;
     }
@@ -376,7 +391,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
     if(!aBoundingCutBuilder->IsDone()) {
       return;
     }
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aBoundingCutBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aBoundingCutBuilder)));
     aResult = aBoundingCutBuilder->Shape();
     if(aResult.ShapeType() == TopAbs_COMPOUND) {
       aResult = GeomAlgoAPI_DFLoader::refineResult(aResult);
@@ -406,7 +422,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
                                                              aBasePlane->Axis().Direction().Z()));
       GeomShapePtr aPln = GeomAlgoAPI_FaceBuilder::planarFace(theCenter, theNormal);
       aList.push_back(aSh);
-      std::list<std::shared_ptr<GeomAPI_Pnt> > aBoundingPoints = GeomAlgoAPI_ShapeTools::getBoundingBox(aList);
+      std::list<std::shared_ptr<GeomAPI_Pnt> >
+        aBoundingPoints = GeomAlgoAPI_ShapeTools::getBoundingBox(aList);
       aSh = GeomAlgoAPI_ShapeTools::fitPlaneToBox(aPln, aBoundingPoints);
       aModifiedBaseShape = aSh->impl<TopoDS_Shape>();
     } else {
@@ -440,7 +457,8 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
       TopoDS_Shape aCutResult = aBaseCutBuilder->Shape();
       TopoDS_Iterator aCheckIt(aCutResult);
       if(aCheckIt.More()) {
-        this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aBaseCutBuilder)));
+        this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+          new GeomAlgoAPI_MakeShape(aBaseCutBuilder)));
         aResult = aCutResult;
         if(aResult.ShapeType() == TopAbs_COMPOUND) {
           aResult = GeomAlgoAPI_DFLoader::refineResult(aResult);
@@ -467,15 +485,19 @@ void GeomAlgoAPI_Revolution::build(const GeomShapePtr&                 theBaseSh
       aResult = aGeomShape->impl<TopoDS_Shape>();
     }
 
-    // If after cut we got more than one solids then take closest to the center of mass of the base face.
+    // If after cut we got more than one solids then take 
+    // closest to the center of mass of the base face.
     aResult = findClosest(aResult, aBaseCentre);
 
     // Setting naming.
     if(aShapeTypeToExp == TopAbs_COMPOUND) {
-      storeGenerationHistory(this, aResult, TopAbs_EDGE, aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
-      storeGenerationHistory(this, aResult, TopAbs_FACE, aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
+      storeGenerationHistory(this, aResult, TopAbs_EDGE, 
+        aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
+      storeGenerationHistory(this, aResult, TopAbs_FACE, 
+        aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
     } else {
-      storeGenerationHistory(this, aResult, aShapeTypeToExp, aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
+      storeGenerationHistory(this, aResult, aShapeTypeToExp, 
+        aRotatedBoundingFace, aModifiedBaseShape, isFromFaceSet);
     }
   }
 
@@ -524,7 +546,7 @@ TopoDS_Solid makeSolidFromShape(const TopoDS_Shape& theShape)
   return aSolid;
 }
 
-//==================================================================================================
+//================================================================================================
 gp_Pnt centreOfMass(const TopoDS_Shape& theShape)
 {
   TopAbs_ShapeEnum aShType = theShape.ShapeType();
@@ -541,7 +563,7 @@ gp_Pnt centreOfMass(const TopoDS_Shape& theShape)
   return aGProps.CentreOfMass();
 }
 
-//==================================================================================================
+//================================================================================================
 TopoDS_Shape findClosest(const TopoDS_Shape& theShape, const gp_Pnt& thePoint)
 {
   TopoDS_Shape aResult = theShape;
@@ -565,7 +587,7 @@ TopoDS_Shape findClosest(const TopoDS_Shape& theShape, const gp_Pnt& thePoint)
   return aResult;
 }
 
-//==================================================================================================
+//================================================================================================
 void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
                             const TopoDS_Shape& theBase,
                             const TopAbs_ShapeEnum theType,
@@ -581,7 +603,7 @@ void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
   }
 }
 
-//==================================================================================================
+//================================================================================================
 void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
                             const TopoDS_Shape& theResult,
                             const TopAbs_ShapeEnum theType,
@@ -594,11 +616,13 @@ void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
     if(theType == TopAbs_VERTEX) {
       gp_Pnt aPnt = BRep_Tool::Pnt(TopoDS::Vertex(aShape));
       IntTools_Context anIntTools;
-      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theToFace), Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theToFace),
+          Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
         theRevolutionAlgo->addToShape(aGeomSh);
       }
-      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theFromFace), Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theFromFace),
+          Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
         theRevolutionAlgo->addFromShape(aGeomSh);
       }
@@ -645,13 +669,17 @@ void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
     if(theType == TopAbs_VERTEX) {
       gp_Pnt aPnt = BRep_Tool::Pnt(TopoDS::Vertex(aShape));
       IntTools_Context anIntTools;
-      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theRotatedBoundingFace), Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theRotatedBoundingFace), 
+          Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : theRevolutionAlgo->addToShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : 
+                           theRevolutionAlgo->addToShape(aGeomSh);
       }
-      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theModifiedBaseShape), Precision::Confusion()) == Standard_True) {
+      if(anIntTools.IsValidPointForFace(aPnt, TopoDS::Face(theModifiedBaseShape),
+         Precision::Confusion()) == Standard_True) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : theRevolutionAlgo->addFromShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : 
+                           theRevolutionAlgo->addFromShape(aGeomSh);
       }
     } else if(theType == TopAbs_EDGE) {
       TopoDS_Edge anEdge = TopoDS::Edge(aShape);
@@ -659,25 +687,30 @@ void storeGenerationHistory(GeomAlgoAPI_Revolution* theRevolutionAlgo,
       anEdgeCheck.Perform();
       if(anEdgeCheck.MaxDistance() < Precision::Confusion()) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : theRevolutionAlgo->addToShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : 
+                           theRevolutionAlgo->addToShape(aGeomSh);
       }
       anEdgeCheck.Init(anEdge, TopoDS::Face(theModifiedBaseShape));
       anEdgeCheck.Perform();
       if(anEdgeCheck.MaxDistance() < Precision::Confusion()) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : theRevolutionAlgo->addFromShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : 
+                           theRevolutionAlgo->addFromShape(aGeomSh);
       }
     } else {
       Handle(Geom_Surface) aFaceSurface = BRep_Tool::Surface(TopoDS::Face(aShape));
-      Handle(Geom_Surface) aBoundingSurface = BRep_Tool::Surface(TopoDS::Face(theRotatedBoundingFace));
+      Handle(Geom_Surface) aBoundingSurface = 
+        BRep_Tool::Surface(TopoDS::Face(theRotatedBoundingFace));
       Handle(Geom_Surface) aBaseSurface = BRep_Tool::Surface(TopoDS::Face(theModifiedBaseShape));
       if(aFaceSurface == aBoundingSurface) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : theRevolutionAlgo->addToShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addFromShape(aGeomSh) : 
+                           theRevolutionAlgo->addToShape(aGeomSh);
       }
       if(aFaceSurface == aBaseSurface) {
         aGeomSh->setImpl(new TopoDS_Shape(aShape));
-        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : theRevolutionAlgo->addFromShape(aGeomSh);
+        theIsFromFaceSet ? theRevolutionAlgo->addToShape(aGeomSh) : 
+                           theRevolutionAlgo->addFromShape(aGeomSh);
       }
     }
   }
index 6a75f2e21beed0bac42c9790ecd76f905f16b71a..7bb8530e4428090d86c64d3168c48345bfefa1bd 100644 (file)
@@ -39,9 +39,11 @@ public:
   /// \brief Creates revolution for the given shape.
   /// \param[in] theBaseShape face for revolution.
   /// \param[in] theAxis axis for revolution.
-  /// \param[in] theToShape to bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theToShape to bounding shape. Can be empty. 
+  ///                       In this case offset will be applied to the basis.
   /// \param[in] theToAngle to angle.
-  /// \param[in] theFromShape from bounding shape. Can be empty. In this case offset will be applied to the basis.
+  /// \param[in] theFromShape from bounding shape. Can be empty. 
+  ///                       In this case offset will be applied to the basis.
   /// \param[in] theFromAngle from angle.
   GEOMALGOAPI_EXPORT GeomAlgoAPI_Revolution(const GeomShapePtr                 theBaseShape,
                                             const std::shared_ptr<GeomAPI_Ax1> theAxis,
index 48f57b50beb28b53a9605a0af0aa89a3ebb93f9d..1ba29f83df3813f4b89a04bed08deb8f940ea6a6 100644 (file)
@@ -122,7 +122,6 @@ std::shared_ptr<GeomAPI_Shape> STEPImport(const std::string& theFileName,
         Standard_Integer nbs = aReader.NbShapes();
         if (!ok || nbs == 0)
         {
-          // THROW_SALOME_CORBA_EXCEPTION("Exception catched in GEOM_Gen_i::ImportStep", SALOME::BAD_PARAM);
           continue; // skip empty root
         }
         /* For a single entity */
@@ -149,7 +148,6 @@ std::shared_ptr<GeomAPI_Shape> STEPImport(const std::string& theFileName,
         for (Standard_Integer i = 1; i <= nbs; i++) {
           TopoDS_Shape aShape = aReader.Shape(i);
           if (aShape.IsNull()) {
-            // THROW_SALOME_CORBA_EXCEPTION("Null shape in GEOM_Gen_i::ImportStep", SALOME::BAD_PARAM) ;
             //return aResShape;
             continue;
           }
index aa11b861ef3ddac0919abd1ae5fa8911ed71f725..19ae526612d0e49d36043a30c312a3d0fc2e6026 100644 (file)
@@ -14,7 +14,8 @@
 
 /// \class GeomAlgoAPI_Sewing
 /// \ingroup DataAlgo
-/// \brief Allows creation of connected topology (shells) from a set of separate topological elements (faces).
+/// \brief Allows creation of connected topology (shells) 
+///        from a set of separate topological elements (faces).
 class GeomAlgoAPI_Sewing : public GeomAlgoAPI_MakeShape
 {
 public:
index 6945ee370c073e720a019e14d159c34add3fca61..8112334bbcf12969222405b5a3b8f7112ab7bbcb 100644 (file)
 
 namespace GeomAlgoAPI_ShapeAPI
 {
-  //=========================================================================================================
-  std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeAPI::makeBox(const double theDx, const double theDy, 
-                                                                const double theDz) throw (GeomAlgoAPI_Exception)
+  //=======================================================================================
+  std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeAPI::makeBox(
+    const double theDx, const double theDy,
+    const double theDz) throw (GeomAlgoAPI_Exception)
   {
     GeomAlgoAPI_Box aBoxAlgo(theDx,theDy,theDz);
     
@@ -37,9 +38,10 @@ namespace GeomAlgoAPI_ShapeAPI
     return aBoxAlgo.shape();
   }
   
-  //=========================================================================================================
-  std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeAPI::makeBox(std::shared_ptr<GeomAPI_Pnt> theFirstPoint,
-                                                                std::shared_ptr<GeomAPI_Pnt> theSecondPoint) throw (GeomAlgoAPI_Exception)
+  //======================================================================================
+  std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeAPI::makeBox(
+    std::shared_ptr<GeomAPI_Pnt> theFirstPoint,
+    std::shared_ptr<GeomAPI_Pnt> theSecondPoint) throw (GeomAlgoAPI_Exception)
   {
     GeomAlgoAPI_BoxPoints aBoxAlgo(theFirstPoint, theSecondPoint);
     
index 02ebef9dd192c8cbf0ec4bc8b0f459e7140b7e88..dc9328be14ea5b12a927781e4ddddca71904a371 100644 (file)
@@ -27,14 +27,15 @@ public:
   /// \param theDy The dimension on Y
   /// \param theDz The dimension on Z
   /// \return a shape
-  static std::shared_ptr<GeomAPI_Shape> makeBox(const double theDx, const double theDy, const double theDz) throw (GeomAlgoAPI_Exception);
+  static std::shared_ptr<GeomAPI_Shape> makeBox(const double theDx, const double theDy, 
+                                                const double theDz) throw (GeomAlgoAPI_Exception);
   
   /// Creates a box using the two points that defined a diagonal.
   /// \param theFirstPoint One extermity of the diagonal
   /// \param theSecondPoint The other extremity of the diagonal
   /// \return a shape
   static std::shared_ptr<GeomAPI_Shape> makeBox(std::shared_ptr<GeomAPI_Pnt> theFirstPoint,
-                                                std::shared_ptr<GeomAPI_Pnt> theSecondPoint) throw (GeomAlgoAPI_Exception);
+                     std::shared_ptr<GeomAPI_Pnt> theSecondPoint) throw (GeomAlgoAPI_Exception);
 };
 }
 #endif
index d710493b9cb46abc2374678f7aa5eb55bf7a0b93..cc3e24bfec990acc9f50c406944e82b2661f3bdd 100644 (file)
@@ -65,7 +65,8 @@ void GeomAlgoAPI_ShapeBuilder::removeInternal(const std::shared_ptr<GeomAPI_Shap
   GeomAPI_Shape::ShapeType aBaseShapeType = theShape->shapeType();
   if(aBaseShapeType == GeomAPI_Shape::WIRE) {
     aResultShape = theShape->emptyCopied();
-    std::shared_ptr<GeomAlgoAPI_MakeShapeCustom> aMakeShapeCustom(new GeomAlgoAPI_MakeShapeCustom());
+    std::shared_ptr<GeomAlgoAPI_MakeShapeCustom>
+      aMakeShapeCustom(new GeomAlgoAPI_MakeShapeCustom());
     for(GeomAPI_ShapeIterator anIter(theShape); anIter.more(); anIter.next()) {
       GeomShapePtr aSubShape = anIter.current();
       GeomShapePtr aSubShapeCopy = aSubShape->emptyCopied();
@@ -82,7 +83,8 @@ void GeomAlgoAPI_ShapeBuilder::removeInternal(const std::shared_ptr<GeomAPI_Shap
   } else if(aBaseShapeType == GeomAPI_Shape::FACE) {
     const TopoDS_Shape& aBaseShape = theShape->impl<TopoDS_Shape>();
     BRepBuilderAPI_Copy* aCopyBuilder = new BRepBuilderAPI_Copy(aBaseShape);
-    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(new GeomAlgoAPI_MakeShape(aCopyBuilder)));
+    this->appendAlgo(std::shared_ptr<GeomAlgoAPI_MakeShape>(
+      new GeomAlgoAPI_MakeShape(aCopyBuilder)));
     if(!aCopyBuilder->IsDone()) {
       return;
     }
@@ -126,7 +128,8 @@ void GeomAlgoAPI_ShapeBuilder::addInternal(const std::shared_ptr<GeomAPI_Shape>
   // Copy sub-shapes from list to new shape.
   BRep_Builder aBuilder;
   std::shared_ptr<GeomAlgoAPI_MakeShapeCustom> aMakeShapeCustom(new GeomAlgoAPI_MakeShapeCustom());
-  for(ListOfShape::const_iterator anIt = theShapesToAdd.cbegin(); anIt != theShapesToAdd.cend(); ++anIt) {
+  for(ListOfShape::const_iterator 
+      anIt = theShapesToAdd.cbegin(); anIt != theShapesToAdd.cend(); ++anIt) {
     TopoDS_Shape aShapeToAdd = (*anIt)->impl<TopoDS_Shape>();
     TopoDS_Shape aModShapeToAdd = aShapeToAdd;
     aModShapeToAdd.Orientation(TopAbs_INTERNAL);
@@ -157,7 +160,8 @@ void GeomAlgoAPI_ShapeBuilder::addInternal(const std::shared_ptr<GeomAPI_Shape>
     if(aBaseShapeType == TopAbs_WIRE) {
       if(aShapeToAddType == TopAbs_VERTEX) {
         // Find on which edge vertex is lie and add to this edge.
-        for(TopExp_Explorer aResultExp(aResultShape, TopAbs_EDGE); aResultExp.More(); aResultExp.Next()) {
+        for(TopExp_Explorer 
+            aResultExp(aResultShape, TopAbs_EDGE); aResultExp.More(); aResultExp.Next()) {
           TopoDS_Shape anEdge = aResultExp.Current();
           BRepExtrema_DistShapeShape aDist(anEdge, aShapeToAdd);
           aDist.Perform();
index 8eb3259c3751a7253efe5e4742ffbd46c53fa8f5..3258f959042fe9dcfe8c13a2ceb3a4b4b191c4a7 100644 (file)
@@ -74,7 +74,8 @@ double GeomAlgoAPI_ShapeTools::volume(const std::shared_ptr<GeomAPI_Shape> theSh
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Pnt> GeomAlgoAPI_ShapeTools::centreOfMass(const std::shared_ptr<GeomAPI_Shape> theShape)
+std::shared_ptr<GeomAPI_Pnt>
+  GeomAlgoAPI_ShapeTools::centreOfMass(const std::shared_ptr<GeomAPI_Shape> theShape)
 {
   GProp_GProps aGProps;
   if(!theShape) {
@@ -98,10 +99,11 @@ std::shared_ptr<GeomAPI_Pnt> GeomAlgoAPI_ShapeTools::centreOfMass(const std::sha
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::shared_ptr<GeomAPI_Shape> theCompound,
-                                                                     const GeomAPI_Shape::ShapeType theType,
-                                                                     ListOfShape& theCombinedShapes,
-                                                                     ListOfShape& theFreeShapes)
+std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(
+  const std::shared_ptr<GeomAPI_Shape> theCompound,
+  const GeomAPI_Shape::ShapeType theType,
+  ListOfShape& theCombinedShapes,
+  ListOfShape& theFreeShapes)
 {
   GeomShapePtr aResult = theCompound;
 
@@ -144,7 +146,8 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::
   // Get all shapes with common subshapes and free shapes.
   NCollection_Map<TopoDS_Shape> aFreeShapes;
   NCollection_Vector<NCollection_Map<TopoDS_Shape>> aShapesWithCommonSubshapes;
-  for(BOPCol_IndexedDataMapOfShapeListOfShape::Iterator anIter(aMapSA); anIter.More(); anIter.Next()) {
+  for(BOPCol_IndexedDataMapOfShapeListOfShape::Iterator 
+      anIter(aMapSA); anIter.More(); anIter.Next()) {
     const TopoDS_Shape& aShape = anIter.Key();
     BOPCol_ListOfShape& aListOfShape = anIter.ChangeValue();
     if(aListOfShape.IsEmpty()) {
@@ -166,9 +169,11 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::
       aFreeShapes.Remove(aF);
       aFreeShapes.Remove(aL);
       aListOfShape.Clear();
-      for(NCollection_List<TopoDS_Shape>::Iterator aTempIter(aTempList); aTempIter.More(); aTempIter.Next()) {
+      for(NCollection_List<TopoDS_Shape>::Iterator 
+          aTempIter(aTempList); aTempIter.More(); aTempIter.Next()) {
         const TopoDS_Shape& aTempShape = aTempIter.Value();
-        for(BOPCol_IndexedDataMapOfShapeListOfShape::Iterator anIter(aMapSA); anIter.More(); anIter.Next()) {
+        for(BOPCol_IndexedDataMapOfShapeListOfShape::Iterator 
+            anIter(aMapSA); anIter.More(); anIter.Next()) {
           BOPCol_ListOfShape& aTempListOfShape = anIter.ChangeValue();
           if(aTempListOfShape.IsEmpty()) {
             continue;
@@ -198,21 +203,25 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::
   }
 
   // Combine shapes with common subshapes.
-  for(NCollection_Vector<NCollection_Map<TopoDS_Shape>>::Iterator anIter(aShapesWithCommonSubshapes); anIter.More(); anIter.Next()) {
+  for(NCollection_Vector<NCollection_Map<TopoDS_Shape>>::Iterator 
+      anIter(aShapesWithCommonSubshapes); anIter.More(); anIter.Next()) {
     TopoDS_Shell aShell;
     TopoDS_CompSolid aCSolid;
     TopoDS_Builder aBuilder;
-    theType == GeomAPI_Shape::COMPSOLID ? aBuilder.MakeCompSolid(aCSolid) : aBuilder.MakeShell(aShell);
+    theType == 
+      GeomAPI_Shape::COMPSOLID ? aBuilder.MakeCompSolid(aCSolid) : aBuilder.MakeShell(aShell);
     NCollection_Map<TopoDS_Shape>& aShapesMap = anIter.ChangeValue();
     for(TopExp_Explorer anExp(aShapesComp, aTA); anExp.More(); anExp.Next()) {
       const TopoDS_Shape& aShape = anExp.Current();
       if(aShapesMap.Contains(aShape)) {
-        theType == GeomAPI_Shape::COMPSOLID ? aBuilder.Add(aCSolid, aShape) : aBuilder.Add(aShell, aShape);
+        theType == 
+          GeomAPI_Shape::COMPSOLID ? aBuilder.Add(aCSolid, aShape) : aBuilder.Add(aShell, aShape);
         aShapesMap.Remove(aShape);
       }
     }
     std::shared_ptr<GeomAPI_Shape> aGeomShape(new GeomAPI_Shape);
-    TopoDS_Shape* aSh = theType == GeomAPI_Shape::COMPSOLID ? new TopoDS_Shape(aCSolid) : new TopoDS_Shape(aShell);
+    TopoDS_Shape* aSh = theType == GeomAPI_Shape::COMPSOLID ? new TopoDS_Shape(aCSolid) : 
+                                                              new TopoDS_Shape(aShell);
     aGeomShape->setImpl<TopoDS_Shape>(aSh);
     theCombinedShapes.push_back(aGeomShape);
   }
@@ -235,10 +244,12 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::
     TopoDS_Compound aResultComp;
     TopoDS_Builder aBuilder;
     aBuilder.MakeCompound(aResultComp);
-    for(ListOfShape::const_iterator anIter = theCombinedShapes.cbegin(); anIter != theCombinedShapes.cend(); anIter++) {
+    for(ListOfShape::const_iterator anIter = theCombinedShapes.cbegin(); 
+        anIter != theCombinedShapes.cend(); anIter++) {
       aBuilder.Add(aResultComp, (*anIter)->impl<TopoDS_Shape>());
     }
-    for(ListOfShape::const_iterator anIter = theFreeShapes.cbegin(); anIter != theFreeShapes.cend(); anIter++) {
+    for(ListOfShape::const_iterator anIter = theFreeShapes.cbegin(); 
+        anIter != theFreeShapes.cend(); anIter++) {
       aBuilder.Add(aResultComp, (*anIter)->impl<TopoDS_Shape>());
     }
     aResult->setImpl(new TopoDS_Shape(aResultComp));
@@ -248,7 +259,8 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::combineShapes(const std::
 }
 
 //==================================================================================================
-static void addSimpleShapeToList(const TopoDS_Shape& theShape, NCollection_List<TopoDS_Shape>& theList)
+static void addSimpleShapeToList(const TopoDS_Shape& theShape, 
+                                 NCollection_List<TopoDS_Shape>& theList)
 {
   if(theShape.IsNull()) {
     return;
@@ -279,7 +291,8 @@ static TopoDS_Compound makeCompound(const NCollection_List<TopoDS_Shape> theShap
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::groupSharedTopology(const std::shared_ptr<GeomAPI_Shape> theCompound)
+std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::groupSharedTopology(
+  const std::shared_ptr<GeomAPI_Shape> theCompound)
 {
   GeomShapePtr aResult = theCompound;
 
@@ -296,14 +309,18 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::groupSharedTopology(const
     NCollection_List<TopoDS_Shape> aGroupedShapes;
     aGroupedShapes.Append(anUngroupedShapes.First());
     anUngroupedShapes.RemoveFirst();
-    for(NCollection_List<TopoDS_Shape>::Iterator aGroupIt(aGroupedShapes); aGroupIt.More(); aGroupIt.Next()) {
+    for(NCollection_List<TopoDS_Shape>::Iterator aGroupIt(aGroupedShapes); 
+        aGroupIt.More(); aGroupIt.Next()) {
       const TopoDS_Shape& aGroupShape = aGroupIt.Value();
-      for(NCollection_List<TopoDS_Shape>::Iterator anUngroupedIt(anUngroupedShapes); anUngroupedIt.More(); anUngroupedIt.Next()) {
+      for(NCollection_List<TopoDS_Shape>::Iterator anUngroupedIt(anUngroupedShapes); 
+          anUngroupedIt.More(); anUngroupedIt.Next()) {
         const TopoDS_Shape& anUngroupedShape = anUngroupedIt.Value();
         bool isFound = false;
-        for(TopExp_Explorer aGroupShapeExp(aGroupShape, TopAbs_VERTEX); aGroupShapeExp.More(); aGroupShapeExp.Next()) {
+        for(TopExp_Explorer aGroupShapeExp(aGroupShape, TopAbs_VERTEX); 
+            aGroupShapeExp.More(); aGroupShapeExp.Next()) {
           const TopoDS_Shape& aVertex1 = aGroupShapeExp.Current();
-          for(TopExp_Explorer anUngroupedShapeExp(anUngroupedShape, TopAbs_VERTEX); anUngroupedShapeExp.More(); anUngroupedShapeExp.Next()) {
+          for(TopExp_Explorer anUngroupedShapeExp(anUngroupedShape, TopAbs_VERTEX); 
+              anUngroupedShapeExp.More(); anUngroupedShapeExp.Next()) {
             const TopoDS_Shape& aVertex2 = anUngroupedShapeExp.Current();
             if(aVertex1.IsSame(aVertex2)) {
               aGroupedShapes.Append(anUngroupedShape);
@@ -328,7 +345,8 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::groupSharedTopology(const
   BRep_Builder aBuilder;
   aBuilder.MakeCompound(aCompound);
   ListOfShape aCompSolids, aFreeSolids;
-  for(NCollection_Vector<NCollection_List<TopoDS_Shape>>::Iterator anIt(aGroups); anIt.More(); anIt.Next()) {
+  for(NCollection_Vector<NCollection_List<TopoDS_Shape>>::Iterator 
+      anIt(aGroups); anIt.More(); anIt.Next()) {
     NCollection_List<TopoDS_Shape> aGroup = anIt.Value();
     GeomShapePtr aGeomShape(new GeomAPI_Shape());
     if(aGroup.Size() == 1) {
@@ -351,13 +369,15 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::groupSharedTopology(const
 }
 
 //==================================================================================================
-std::list<std::shared_ptr<GeomAPI_Pnt> > GeomAlgoAPI_ShapeTools::getBoundingBox(const ListOfShape& theShapes, const double theEnlarge)
+std::list<std::shared_ptr<GeomAPI_Pnt> >
+  GeomAlgoAPI_ShapeTools::getBoundingBox(const ListOfShape& theShapes, const double theEnlarge)
 {
   // Bounding box of all objects.
   Bnd_Box aBndBox;
 
   // Getting box.
-  for (ListOfShape::const_iterator anObjectsIt = theShapes.begin(); anObjectsIt != theShapes.end(); anObjectsIt++) {
+  for (ListOfShape::const_iterator 
+    anObjectsIt = theShapes.begin(); anObjectsIt != theShapes.end(); anObjectsIt++) {
     const TopoDS_Shape& aShape = (*anObjectsIt)->impl<TopoDS_Shape>();
     BRepBndLib::Add(aShape, aBndBox);
   }
@@ -385,7 +405,8 @@ std::list<std::shared_ptr<GeomAPI_Pnt> > GeomAlgoAPI_ShapeTools::getBoundingBox(
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::faceToInfinitePlane(const std::shared_ptr<GeomAPI_Shape> theFace)
+std::shared_ptr<GeomAPI_Shape> 
+  GeomAlgoAPI_ShapeTools::faceToInfinitePlane(const std::shared_ptr<GeomAPI_Shape> theFace)
 {
   if (!theFace.get())
     return std::shared_ptr<GeomAPI_Shape>();
@@ -407,8 +428,9 @@ std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::faceToInfinitePlane(const
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_ShapeTools::fitPlaneToBox(const std::shared_ptr<GeomAPI_Shape> thePlane,
-                                                                    const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints)
+std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_ShapeTools::fitPlaneToBox(
+  const std::shared_ptr<GeomAPI_Shape> thePlane,
+  const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints)
 {
   std::shared_ptr<GeomAPI_Face> aResultFace;
 
@@ -441,7 +463,8 @@ std::shared_ptr<GeomAPI_Face> GeomAlgoAPI_ShapeTools::fitPlaneToBox(const std::s
   IntAna_Quadric aQuadric(aFacePln);
   Standard_Real UMin, UMax, VMin, VMax;
   UMin = UMax = VMin = VMax = 0;
-  for (std::list<std::shared_ptr<GeomAPI_Pnt> >::const_iterator aPointsIt = thePoints.begin(); aPointsIt != thePoints.end(); aPointsIt++) {
+  for (std::list<std::shared_ptr<GeomAPI_Pnt> >::const_iterator 
+       aPointsIt = thePoints.begin(); aPointsIt != thePoints.end(); aPointsIt++) {
     const gp_Pnt& aPnt = (*aPointsIt)->impl<gp_Pnt>();
     gp_Lin aLin(aPnt, aFacePln.Axis().Direction());
     IntAna_IntConicQuad anIntAna(aLin, aQuadric);
@@ -544,8 +567,9 @@ std::shared_ptr<GeomAPI_Pln> GeomAlgoAPI_ShapeTools::findPlane(const ListOfShape
 }
 
 //==================================================================================================
-bool GeomAlgoAPI_ShapeTools::isSubShapeInsideShape(const std::shared_ptr<GeomAPI_Shape> theSubShape,
-                                                   const std::shared_ptr<GeomAPI_Shape> theBaseShape)
+bool GeomAlgoAPI_ShapeTools::isSubShapeInsideShape(
+  const std::shared_ptr<GeomAPI_Shape> theSubShape,
+  const std::shared_ptr<GeomAPI_Shape> theBaseShape)
 {
   if(!theSubShape.get() || !theBaseShape.get()) {
     return false;
@@ -595,7 +619,9 @@ bool GeomAlgoAPI_ShapeTools::isSubShapeInsideShape(const std::shared_ptr<GeomAPI
 
       // No intersections found. Edge is inside or outside face. Check it.
       BRepAdaptor_Curve aCurveAdaptor(anEdge);
-      gp_Pnt aPointToCheck = aCurveAdaptor.Value((aCurveAdaptor.FirstParameter() + aCurveAdaptor.LastParameter()) / 2.0);
+      gp_Pnt aPointToCheck =
+        aCurveAdaptor.Value((aCurveAdaptor.FirstParameter() + 
+                              aCurveAdaptor.LastParameter()) / 2.0);
       Handle(Geom_Surface) aSurface = BRep_Tool::Surface(aFace);
       ShapeAnalysis_Surface aSAS(aSurface);
       gp_Pnt2d aPointOnFace = aSAS.ValueOfUV(aPointToCheck, Precision::Confusion());
@@ -626,7 +652,8 @@ bool GeomAlgoAPI_ShapeTools::isShapeValid(const std::shared_ptr<GeomAPI_Shape> t
 }
 
 //==================================================================================================
-std::shared_ptr<GeomAPI_Shape> GeomAlgoAPI_ShapeTools::getFaceOuterWire(const std::shared_ptr<GeomAPI_Shape> theFace)
+std::shared_ptr<GeomAPI_Shape> 
+  GeomAlgoAPI_ShapeTools::getFaceOuterWire(const std::shared_ptr<GeomAPI_Shape> theFace)
 {
   GeomShapePtr anOuterWire;
 
index cadedc031b78b453c9b3d8279a37838817cd5e93..49aaef252d44938c9e40279d3a05d486f01fd381 100644 (file)
@@ -30,40 +30,49 @@ public:
   /// \return the total volume of the solids of the current shape or 0.0 if it can be computed.
   GEOMALGOAPI_EXPORT static double volume(const std::shared_ptr<GeomAPI_Shape> theShape);
 
-  /// \return the centre of mass of the current face. The coordinates returned for the center of mass
-  /// are expressed in the absolute Cartesian coordinate system. (This function works only for surfaces).
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Pnt> centreOfMass(const std::shared_ptr<GeomAPI_Shape> theShape);
+  /// \return the centre of mass of the current face. 
+  /// The coordinates returned for the center of mass
+  /// are expressed in the absolute Cartesian coordinate system. 
+  /// (This function works only for surfaces).
+  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Pnt> 
+    centreOfMass(const std::shared_ptr<GeomAPI_Shape> theShape);
 
   /// \brief Combines faces with common edges to shells, or solids to compsolids.
   /// \param[in] theCompound compound of shapes.
   /// \param[in] theType type of combine.
   /// \param[out] theCombinedShapes resulting shapes.
   /// \param[out] theFreeShapes shapes that does not have common subshapes.
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> combineShapes(const std::shared_ptr<GeomAPI_Shape> theCompound,
-                                                                         const GeomAPI_Shape::ShapeType theType,
-                                                                         ListOfShape& theCombinedShapes,
-                                                                         ListOfShape& theFreeShapes);
+  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> combineShapes(
+    const std::shared_ptr<GeomAPI_Shape> theCompound,
+    const GeomAPI_Shape::ShapeType theType,
+    ListOfShape& theCombinedShapes,
+    ListOfShape& theFreeShapes);
 
   /// \brief Groups shapes with shared topology to compounds.
   /// \param[in] theCompound compound of shapes.
   /// \return compound of compounds with shared topology.
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> groupSharedTopology(const std::shared_ptr<GeomAPI_Shape> theCompound);
+  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> 
+    groupSharedTopology(const std::shared_ptr<GeomAPI_Shape> theCompound);
 
   /// \brief Calculates bounding box for theShapes
   /// \return list of eight points.
   /// \param[in] theShapes list of shapes.
   /// \param[in] theEnlarge enlarges bounding box size.
-  GEOMALGOAPI_EXPORT static std::list<std::shared_ptr<GeomAPI_Pnt> > getBoundingBox(const ListOfShape& theShapes, const double theEnlarge = 0.0);
+  GEOMALGOAPI_EXPORT static 
+    std::list<std::shared_ptr<GeomAPI_Pnt> > getBoundingBox(const ListOfShape& theShapes, 
+                                                            const double theEnlarge = 0.0);
 
   /// \return infinite plane received from theFace plane.
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> faceToInfinitePlane(const std::shared_ptr<GeomAPI_Shape> theFace);
+  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> 
+    faceToInfinitePlane(const std::shared_ptr<GeomAPI_Shape> theFace);
 
   /// \brief Enlarges or reduces plane to fit bounding box.
   /// \return plane that fits to bounding box.
   /// \param[in] thePlane base plane.
   /// \param[in] thePoints bounding box points (shoud be eight).
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Face> fitPlaneToBox(const std::shared_ptr<GeomAPI_Shape> thePlane,
-                                                                        const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints);
+  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Face> fitPlaneToBox(
+    const std::shared_ptr<GeomAPI_Shape> thePlane,
+    const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints);
 
   /// \brief Finds the start and end vertices of theShape. theShape can be of the following type:\n
   /// Vertex: theV1 and theV2 are the same and equal to theShape;\n
@@ -79,9 +88,9 @@ public:
   /// \param[in] theWires base wires.
   /// \param[out] theFaces resulting faces.
   GEOMALGOAPI_EXPORT static void makeFacesWithHoles(const std::shared_ptr<GeomAPI_Pnt> theOrigin,
-                                                    const std::shared_ptr<GeomAPI_Dir> theDirection,
-                                                    const ListOfShape& theWires,
-                                                    ListOfShape& theFaces);
+                                                const std::shared_ptr<GeomAPI_Dir> theDirection,
+                                                const ListOfShape& theWires,
+                                                ListOfShape& theFaces);
 
   /// \brief Return a plane for list of shapes if they are all planar.
   /// \param[in] theShapes shapes to find plane.
@@ -92,14 +101,16 @@ public:
   /// \param[in] theSubShape shape that should be inside.
   /// \param[in] theBaseShape base shape.
   /// \return true if edge inside the face.
-  GEOMALGOAPI_EXPORT static bool isSubShapeInsideShape(const std::shared_ptr<GeomAPI_Shape> theSubShape,
-                                                       const std::shared_ptr<GeomAPI_Shape> theBaseShape);
+  GEOMALGOAPI_EXPORT static bool isSubShapeInsideShape(
+    const std::shared_ptr<GeomAPI_Shape> theSubShape,
+    const std::shared_ptr<GeomAPI_Shape> theBaseShape);
 
   /// \return true if theShape is valid.
   GEOMALGOAPI_EXPORT static bool isShapeValid(const std::shared_ptr<GeomAPI_Shape> theShape);
 
   /// \return outer wire for face. If theShape has different type returns empty pointer.
-  GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> getFaceOuterWire(const std::shared_ptr<GeomAPI_Shape> theFace);
+  GEOMALGOAPI_EXPORT static 
+    std::shared_ptr<GeomAPI_Shape> getFaceOuterWire(const std::shared_ptr<GeomAPI_Shape> theFace);
 
   /// \return true if edge is parallel to face.
   GEOMALGOAPI_EXPORT static bool isParallel(const std::shared_ptr<GeomAPI_Edge> theEdge,
@@ -110,13 +121,13 @@ public:
   /// \param[in] thePoints container of points to split
   /// \param[out] theShapes container of shapes after split
   GEOMALGOAPI_EXPORT static void splitShape(const std::shared_ptr<GeomAPI_Shape>& theBaseShape,
-                                            const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints,
-                                            std::set<std::shared_ptr<GeomAPI_Shape> >& theShapes);
+                                      const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints,
+                                      std::set<std::shared_ptr<GeomAPI_Shape> >& theShapes);
 
 
   GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> findShape(
-                                              const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints,
-                                              const std::set<std::shared_ptr<GeomAPI_Shape> >& theShapes);
+                                    const std::list<std::shared_ptr<GeomAPI_Pnt> >& thePoints,
+                                    const std::set<std::shared_ptr<GeomAPI_Shape> >& theShapes);
 
 };
 
index 880273df25fe4665fa09d37cd3649dfca5df5be9..2bd7775e3cc83019cea1c3ce53451263c73a5668 100644 (file)
@@ -147,7 +147,7 @@ void GeomAlgoAPI_SketchBuilder::createFaces(const std::shared_ptr<GeomAPI_Pnt>&
                                             const std::shared_ptr<GeomAPI_Dir>& theDirX,
                                             const std::shared_ptr<GeomAPI_Dir>& theNorm,
                                             const std::shared_ptr<GeomAPI_Shape>& theWire,
-                                            std::list<std::shared_ptr<GeomAPI_Shape> >& theResultFaces)
+                                std::list<std::shared_ptr<GeomAPI_Shape> >& theResultFaces)
 {
   std::shared_ptr<GeomAPI_PlanarEdges> aWire = 
     std::dynamic_pointer_cast<GeomAPI_PlanarEdges>(theWire);
index 99256bee66abe591e8df6a88efbc90e2b8eb0ee2..7f39131444e28e113e54633ad270d27f51c0c74b 100644 (file)
@@ -19,7 +19,8 @@ class GeomAlgoAPI_WireBuilder
  public:
    /// \brief Creates a wire from edges and wires.
    /// \param[in] theShapes list of shapes. Only edges and wires allowed.
-   /// The edges are not to be consecutive. But they are to be all connected geometrically or topologically.
+   /// The edges are not to be consecutive. 
+   /// But they are to be all connected geometrically or topologically.
    /// \return wire created from theShapes. Empty in case of error or bad input.
    GEOMALGOAPI_EXPORT static std::shared_ptr<GeomAPI_Shape> wire(const ListOfShape& theShapes);
 };