20 #ifndef GeomAPI_Lin_H_
21 #define GeomAPI_Lin_H_
23 #include <GeomAPI_Interface.h>
39 GeomAPI_Lin(
const double theStartX,
const double theStartY,
const double theStartZ,
40 const double theEndX,
const double theEndY,
const double theEndZ);
43 GeomAPI_Lin(
const std::shared_ptr<GeomAPI_Pnt>& theStart,
44 const std::shared_ptr<GeomAPI_Pnt>& theEnd);
47 GeomAPI_Lin(
const std::shared_ptr<GeomAPI_Pnt>& theOrigin,
48 const std::shared_ptr<GeomAPI_Dir>& theDirection);
52 std::shared_ptr<GeomAPI_Pnt>
location();
60 double distance(
const std::shared_ptr<GeomAPI_Pnt>& thePoint)
const;
63 const std::shared_ptr<GeomAPI_Pnt>
intersect(
64 const std::shared_ptr<GeomAPI_Lin>& theLine)
const;
67 const std::shared_ptr<GeomAPI_Pnt>
project(
68 const std::shared_ptr<GeomAPI_Pnt>& thePoint)
const;
72 double projParam(
const std::shared_ptr<GeomAPI_Pnt>& thePoint)
const;
78 bool contains(
const std::shared_ptr<GeomAPI_Pnt> thePoint,
79 const double theLinearTolerance = 1.e-7)
const;
83 bool isParallel(
const std::shared_ptr<GeomAPI_Lin> theLin)
const;
87 bool isCoplanar(
const std::shared_ptr<GeomAPI_Lin> theLin)
const;
91 typedef std::shared_ptr<GeomAPI_Lin> GeomLinePtr;
3D direction defined by three normalized coordinates
Definition: GeomAPI_Dir.h:34
General base class for all interfaces in this package.
Definition: GeomAPI_Interface.h:38
Line in 3D.
Definition: GeomAPI_Lin.h:35
GEOMAPI_EXPORT bool isParallel(const std::shared_ptr< GeomAPI_Lin > theLin) const
Definition: GeomAPI_Lin.cpp:138
GEOMAPI_EXPORT const std::shared_ptr< GeomAPI_Pnt > project(const std::shared_ptr< GeomAPI_Pnt > &thePoint) const
Project point on line.
Definition: GeomAPI_Lin.cpp:118
GEOMAPI_EXPORT bool isCoplanar(const std::shared_ptr< GeomAPI_Lin > theLin) const
Definition: GeomAPI_Lin.cpp:144
GEOMAPI_EXPORT GeomAPI_Lin(const double theStartX, const double theStartY, const double theStartZ, const double theEndX, const double theEndY, const double theEndZ)
Creation of line defined by coordinates of start and end points.
Definition: GeomAPI_Lin.cpp:46
GEOMAPI_EXPORT const std::shared_ptr< GeomAPI_Pnt > intersect(const std::shared_ptr< GeomAPI_Lin > &theLine) const
Intersection of two lines.
Definition: GeomAPI_Lin.cpp:85
GEOMAPI_EXPORT std::shared_ptr< GeomAPI_Dir > direction()
Returns a line direction.
Definition: GeomAPI_Lin.cpp:74
GEOMAPI_EXPORT double projParam(const std::shared_ptr< GeomAPI_Pnt > &thePoint) const
Returns parameter of the point projection.
Definition: GeomAPI_Lin.cpp:109
GEOMAPI_EXPORT std::shared_ptr< GeomAPI_Pnt > location()
Returns point on the line (first point)
Definition: GeomAPI_Lin.cpp:68
GEOMAPI_EXPORT bool contains(const std::shared_ptr< GeomAPI_Pnt > thePoint, const double theLinearTolerance=1.e-7) const
Definition: GeomAPI_Lin.cpp:128
GEOMAPI_EXPORT double distance(const std::shared_ptr< GeomAPI_Pnt > &thePoint) const
Distance between two points.
Definition: GeomAPI_Lin.cpp:80
3D point defined by three coordinates
Definition: GeomAPI_Pnt.h:38