3D segment, consisting of two points.
Definition at line 726 of file lightweight_geom_data.h.
#include <mrpt/math/lightweight_geom_data.h>
Public Member Functions | |
double | length () const |
Segment length. More... | |
double | distance (const TPoint3D &point) const |
Distance to point. More... | |
double | distance (const TSegment3D &segment) const |
Distance to another segment. More... | |
bool | contains (const TPoint3D &point) const |
Check whether a point is inside the segment. More... | |
TPoint3D & | operator[] (size_t i) |
Unsafe point access using [] operator, intended for loops. More... | |
const TPoint3D & | operator[] (size_t i) const |
Unsafe point access using [] operator, intended for loops. More... | |
void | generate2DObject (TSegment2D &s) const |
Projection into 2D space, discarding the z. More... | |
void | getCenter (TPoint3D &p) const |
Segment's central point. More... | |
TSegment3D (const TPoint3D &p1, const TPoint3D &p2) | |
Constructor from both points. More... | |
TSegment3D () | |
Fast default constructor. More... | |
TSegment3D (const TSegment2D &s) | |
Constructor from 2D object. More... | |
bool | operator< (const TSegment3D &s) const |
Public Attributes | |
TPoint3D | point1 |
Origin point. More... | |
TPoint3D | point2 |
Destiny point. More... | |
Constructor from both points.
Definition at line 781 of file lightweight_geom_data.h.
|
inline |
Fast default constructor.
Initializes to garbage.
Definition at line 785 of file lightweight_geom_data.h.
|
inline |
Constructor from 2D object.
Sets the z to zero.
Definition at line 789 of file lightweight_geom_data.h.
bool mrpt::math::TSegment3D::contains | ( | const TPoint3D & | point | ) | const |
Check whether a point is inside the segment.
double mrpt::math::TSegment3D::distance | ( | const TPoint3D & | point | ) | const |
Distance to point.
double mrpt::math::TSegment3D::distance | ( | const TSegment3D & | segment | ) | const |
Distance to another segment.
|
inline |
Projection into 2D space, discarding the z.
Definition at line 767 of file lightweight_geom_data.h.
|
inline |
Segment's central point.
Definition at line 773 of file lightweight_geom_data.h.
References mrpt::math::TPoint3D::x, mrpt::math::TPoint3D::y, and mrpt::math::TPoint3D::z.
double mrpt::math::TSegment3D::length | ( | ) | const |
Segment length.
bool mrpt::math::TSegment3D::operator< | ( | const TSegment3D & | s | ) | const |
|
inline |
Unsafe point access using [] operator, intended for loops.
Definition at line 755 of file lightweight_geom_data.h.
|
inline |
Unsafe point access using [] operator, intended for loops.
Definition at line 761 of file lightweight_geom_data.h.
TPoint3D mrpt::math::TSegment3D::point1 |
Origin point.
Definition at line 731 of file lightweight_geom_data.h.
Referenced by mrpt::math::TPlane::contains(), mrpt::math::operator!=(), mrpt::math::operator<<(), mrpt::math::operator==(), and mrpt::math::operator>>().
TPoint3D mrpt::math::TSegment3D::point2 |
Destiny point.
Definition at line 735 of file lightweight_geom_data.h.
Referenced by mrpt::math::TPlane::contains(), mrpt::math::operator!=(), mrpt::math::operator<<(), mrpt::math::operator==(), and mrpt::math::operator>>().
Page generated by Doxygen 1.8.14 for MRPT 1.0.2 SVN: at lun oct 28 00:52:41 CET 2019 | Hosted on: |