29 #include "../pos_vec/Pos3d.h" 36 typedef std::pair<int,int> int_pair;
37 typedef std::deque<int_pair> int_pair_deque;
51 const CGSegment_3 &ToCGAL(
void)
const 55 void TwoPoints(
const Pos3d &p1,
const Pos3d &p2);
56 virtual GEOM_FT
GetMax(
unsigned short int i)
const;
57 virtual GEOM_FT
GetMin(
unsigned short int i)
const;
58 Line3d getSupportLine(
void)
const;
59 Pos3d getFromPoint(
void)
const;
60 Pos3d getToPoint(
void)
const;
64 const Pos3d Point(
const int &i)
const;
70 bool isDegenerated(
void)
const;
71 virtual bool In(
const Pos3d &p,
const double &tol= 0.0)
const;
76 bool isParallel(
const Line3d &r)
const;
77 bool isParallel(
const Ray3d &sr)
const;
78 bool isParallel(
const Segment3d &r)
const;
90 virtual Pos3d getCenterOfMass(
void)
const;
91 Dir3d GetDir(
void)
const;
105 virtual GEOM_FT
Ix(
void)
const;
106 virtual GEOM_FT
Iy(
void)
const;
107 virtual GEOM_FT
Iz(
void)
const;
110 boost::python::list
DividePy(
int num_partes)
const;
112 boost::python::list
DividePy(
const boost::python::list &)
const;
113 boost::python::list
split(
const Pos3d &)
const;
115 boost::python::dict
getPyDict(
void)
const;
116 void setPyDict(
const boost::python::dict &);
118 void Print(std::ostream &os)
const;
122 {
return r.
dist2(p); }
124 {
return dist2(p,r); }
127 {
return dist(p,r); }
130 {
return sg.isParallel(r); }
132 {
return parallel(sg,r); }
134 {
return sg.isParallel(sr); }
136 {
return parallel(sg,sr); }
138 {
return r1.isParallel(r2); }
141 {
return colineales(sg.getSupportLine(),r); }
143 {
return colineales(sg,r); }
145 {
return colineales(sg.getSupportLine(),sr); }
147 {
return colineales(sg,sr); }
149 {
return colineales(sg1,sg2.getSupportLine()); }
162 int_pair_deque getIntersections(
const std::deque<Segment3d> &);
164 std::list<Polyline3d> get_polylines(
const std::list<Segment3d> &,
const GEOM_FT &tol);
165 boost::python::list py_get_3d_polylines(
const boost::python::list &,
const GEOM_FT &tol);
Pos3d getPointNaturalCoord(const GEOM_FT &chi) const
Return the parametric coordinate that corresponds to the natural coordinate being passed as parameter...
Definition: Segment3d.cc:121
Pos3d Projection(const Pos3d &) const
Return the orthogonal projection onto the line.
Definition: Segment3d.cc:328
virtual GEOM_FT dist2(const Pos3d &p) const
Return the squared distance from the point to the segment.
Definition: Segment3d.cc:168
bool upwards(void) const
Return true if the segment goes up.
Definition: Segment3d.cc:96
virtual Vector3d getJVector(void) const
Returns a vector in the direction of the local Y axis.
Definition: Segment3d.cc:150
Segment en tres dimensiones.
Definition: Segment3d.h:42
virtual GeomObj * getCopy(void) const
Virtual constructor.
Definition: Segment3d.cc:73
virtual GEOM_FT GetMin(unsigned short int i) const
Return the minimum value of the i-th coordinate.
Definition: Segment3d.cc:82
virtual GEOM_FT getLength(void) const
Return the length of the segment.
Definition: Segment3d.cc:199
Polyline in a three-dimensional space.
Definition: Polyline3d.h:37
bool connected(const Pos3d &, const GEOM_FT &tol=0.0) const
Return true if the segment is connected to the argument point (i.
Definition: Segment3d.cc:313
GEOM_FT getAngle(const Vector3d &) const
Returns the angle with the vector argument.
Definition: Segment3d.cc:347
Plane in a three-dimensional space.
Definition: Plane.h:49
boost::python::dict getPyDict(void) const
Return a Python dictionary with the object members values.
Definition: Segment3d.cc:489
void swap(void)
@ brief Swaps the segment orientation.
Definition: Segment3d.cc:77
boost::python::list DividePy(int num_partes) const
Return a Python list containing the points that results from the segment division.
Definition: Segment3d.cc:409
Pos3d getMidPoint(void) const
Return the mid point of the segment.
Definition: Segment3d.cc:111
Ray in a three-dimensional space.
Definition: Ray3d.h:36
Base class for the objects involving a single dimension in a three-dimensional space.
Definition: Linear3d.h:33
GEOM_FT getAngleXYPlane(void) const
Returns angle with the XY plane.
Definition: Segment3d.cc:367
virtual bool In(const Pos3d &p, const double &tol=0.0) const
Return true if the point is in the segment.
Definition: Segment3d.cc:127
void setPyDict(const boost::python::dict &)
Set the values of the object members from a Python dictionary.
Definition: Segment3d.cc:498
GEOM_FT getSlope(void) const
Return the angle or the line with respect to XY plane.
Definition: Segment3d.cc:92
virtual Vector3d getIVector(void) const
Returns a vector in the direction of the local X axis.
Definition: Segment3d.cc:145
boost::python::list split(const Pos3d &) const
Return the two segments that result from splitting this one on the point nearest to the argument...
Definition: Segment3d.cc:468
virtual GEOM_FT GetMax(unsigned short int i) const
Return the maximum value of the i-th coordinate.
Definition: Segment3d.cc:80
Dirección en el espacio de tres dimensiones.
Definition: Dir3d.h:35
Segment3d(void)
Constructor.
Definition: Segment3d.cc:39
GEOM_FT getAngleXZPlane(void) const
Returns angle with the XZ plane.
Definition: Segment3d.cc:373
void Put(const Pos3d &p1, const Pos3d &p2)
Set the extremities of the segment.
Definition: Segment3d.cc:140
Pos3d PtoParametricas(const GEOM_FT &lambda) const
Return a point of the line at a distance lambda from its origin.
Definition: Segment3d.cc:107
bool downwards(void) const
Return true if the segment goes down.
Definition: Segment3d.cc:100
Posición en tres dimensiones.
Definition: Pos3d.h:44
VectorPos3d Divide(int num_partes) const
Return the points that results from the segment division.
Definition: Segment3d.cc:402
virtual GEOM_FT Iz(void) const
Moment of inertia with respect to the center of mass in local coordinates.
Definition: Segment3d.cc:396
virtual GEOM_FT Iy(void) const
Moment of inertia with respect to the center of mass in local coordinates.
Definition: Segment3d.cc:392
Line in a three-dimensional space.
Definition: Line3d.h:62
GEOM_FT getLambda(const Pos3d &p) const
Return the lambda parameter for the given point: p= getFromPoint()+lambda*VDir()
Definition: Segment3d.cc:160
virtual bool operator==(const Segment3d &) const
Comparison operator.
Definition: Segment3d.cc:58
virtual Vector3d getKVector(void) const
Returns a vector in the direction of the local Z axis.
Definition: Segment3d.cc:155
Vector de posiciones en tres dimensiones [(x1,y1,z1),(x1,y2,z2),...].
Definition: VectorPos3d.h:32
GEOM_FT getAngleYZPlane(void) const
Returns angle with the YZ plane.
Definition: Segment3d.cc:379
Clase base para las entidades geométricas.
Definition: GeomObj.h:40
GEOM_FT dist(const Pos3d &p) const
Return the distance from the point to the segment.
Definition: Segment3d.cc:188
double getParamNaturalCoord(const GEOM_FT &) const
Return the parametric coordinate that corresponds to the natural coordinate being passed as parameter...
Definition: Segment3d.cc:116
GeomObj3d::list_Pos3d getIntersection(unsigned short int, const double &) const
Return the intersection of the line with the plane defined by the equation coord_i=cte.
Definition: Segment3d.cc:265
Vector en tres dimensiones.
Definition: Vector3d.h:39
virtual GEOM_FT Ix(void) const
Moment of inertia with respect to the center of mass in local coordinates.
Definition: Segment3d.cc:388