X-Git-Url: http://git.salome-platform.org/gitweb/?a=blobdiff_plain;f=src%2FGeomAlgoAPI%2FGeomAlgoAPI_ShapeTools.h;h=f69ad5cd56ef1c0c0657c2eeeb63dc4750ac400b;hb=f0cec241aae9ca16d86e166f45cb5c4987d2c792;hp=8df74080a76f06a7c83d88a0e283d85010a287d9;hpb=78205c43afb89dee242a940236c22000df5af987;p=modules%2Fshaper.git diff --git a/src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.h b/src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.h index 8df74080a..f69ad5cd5 100644 --- a/src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.h +++ b/src/GeomAlgoAPI/GeomAlgoAPI_ShapeTools.h @@ -12,7 +12,11 @@ #include #include +#include + +class GeomAPI_Edge; class GeomAPI_Dir; +class GeomAPI_Face; class GeomAPI_PlanarEdges; class GeomAPI_Pln; class GeomAPI_Pnt; @@ -58,8 +62,8 @@ public: /// \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 fitPlaneToBox(const std::shared_ptr thePlane, - const std::list >& thePoints); + GEOMALGOAPI_EXPORT static std::shared_ptr fitPlaneToBox(const std::shared_ptr thePlane, + const std::list >& 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 @@ -94,6 +98,19 @@ public: /// \return true if theShape is valid. GEOMALGOAPI_EXPORT static bool isShapeValid(const std::shared_ptr theShape); + /// \return outer wire for face. If theShape has different type returns empty pointer. + GEOMALGOAPI_EXPORT static std::shared_ptr getFaceOuterWire(const std::shared_ptr theFace); + + /// \return true if edge is parallel to face. + GEOMALGOAPI_EXPORT static bool isParallel(const std::shared_ptr theEdge, + const std::shared_ptr theFace); + /// \brief Performs the split of the shape by points. + /// \param[in] theBaseShape shape that should be splitted. + /// \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& theBaseShape, + const std::set >& thePoints, + std::set >& theShapes); }; #endif