Salome HOME
b7b97aa7ee6818e881ed2106c38d0dd3e79adc09
[modules/shaper.git] / src / GeomAlgoAPI / GeomAlgoAPI_EdgeBuilder.h
1 // Copyright (C) 2014-20xx CEA/DEN, EDF R&D
2
3 // File:        GeomAlgoAPI_EdgeBuilder.h
4 // Created:     23 Apr 2014
5 // Author:      Mikhail PONIKAROV
6
7 #ifndef GeomAlgoAPI_EdgeBuilder_H_
8 #define GeomAlgoAPI_EdgeBuilder_H_
9
10 #include <GeomAlgoAPI.h>
11 #include <GeomAPI_Edge.h>
12 #include <GeomAPI_Pnt.h>
13 #include <GeomAPI_Dir.h>
14 #include <memory>
15
16 /**\class GeomAlgoAPI_EdgeBuilder
17  * \ingroup DataAlgo
18  * \brief Allows to create face-shapes by different parameters
19  */
20
21 class GEOMALGOAPI_EXPORT GeomAlgoAPI_EdgeBuilder
22 {
23  public:
24   /// Creates linear edge by two points.
25   /// \param theStart a first point of an edge
26   /// \param theEnd an end point of an edge
27   static std::shared_ptr<GeomAPI_Edge> line(std::shared_ptr<GeomAPI_Pnt> theStart,
28                                             std::shared_ptr<GeomAPI_Pnt> theEnd);
29
30   /// Creates linear edge by three dimensions.
31   /// \param theX the X dimension
32   /// \param theY the Y dimension
33   /// \param theZ the Z dimension
34   static std::shared_ptr<GeomAPI_Edge> line(double theDX,
35                                             double theDY,
36                                             double theDZ);
37
38   /// Creates edge - axis of the given cylindrical face. The result axis edge is infinite
39   static std::shared_ptr<GeomAPI_Edge> cylinderAxis(
40     std::shared_ptr<GeomAPI_Shape> theCylindricalFace);
41
42   /// Creates linear edge in a form of a circle by a point and a circle radius
43   static std::shared_ptr<GeomAPI_Edge> lineCircle(std::shared_ptr<GeomAPI_Pnt> theCenter,
44                                                     std::shared_ptr<GeomAPI_Dir> theNormal,
45                                                     double theRadius);
46
47   /// Creates linear edge in a form of a circle arc by a three points
48   static std::shared_ptr<GeomAPI_Edge> lineCircleArc(std::shared_ptr<GeomAPI_Pnt> theCenter,
49                                                        std::shared_ptr<GeomAPI_Pnt> theStartPoint,
50                                                        std::shared_ptr<GeomAPI_Pnt> theEndPoint,
51                                                        std::shared_ptr<GeomAPI_Dir> theNormal);
52 };
53
54 #endif