77 float x0,
float y0,
float z0,
float x1,
float y1,
float z1)
117 template <
class T_it>
148 template <
class T,
class U>
151 appendLine(p0.x, p0.y, p0.z, p1.x, p1.y, p1.z);
170 size_t index,
double x0,
double y0,
double z0,
double x1,
double y1,
184 size_t index,
double& x0,
double& y0,
double& z0,
double& x1,
185 double& y1,
double& z1)
const;
191 using iterator = std::vector<mrpt::math::TSegment3D>::iterator;
193 std::vector<mrpt::math::TSegment3D>::reverse_iterator;
196 std::vector<mrpt::math::TSegment3D>::const_reverse_iterator;
245 const std::vector<mrpt::math::TSegment3D>& sgms,
246 bool antiAliasing =
true);
256 l->appendLines(
s.begin(),
s.end());
size_t size() const
Returns the total count of lines in this set.
std::vector< mrpt::math::TSegment3D > mSegments
void enableAntiAliasing(bool enable=true)
void notifyChange() const
Must be called to notify that the object has changed (so, the display list must be updated) ...
void setLineByIndex(size_t index, double x0, double y0, double z0, double x1, double y1, double z1)
Sets a specific line in the set, given its index.
void appendLines(const T &sgms)
Appends any iterable collection of lines to the set.
void appendLineStrip(float x, float y, float z)
Appends a line whose starting point is the end point of the last line (similar to OpenGL's GL_LINE_ST...
const_iterator begin() const
Beginning const iterator.
mrpt::serialization::CArchive & operator<<(mrpt::serialization::CArchive &out, const mrpt::opengl::CLight &o)
size_t getLineCount() const
Returns the total count of lines in this set.
void getLineByIndex(size_t index, double &x0, double &y0, double &z0, double &x1, double &y1, double &z1) const
Gets a specific line in the set, given its index.
const_iterator end() const
Ending const iterator.
void setLineWidth(float w)
Sets the width with which lines will be drawn.
void resize(size_t nLines)
Resizes the set.
float m_verticesPointSize
0: means hidden
std::vector< mrpt::math::TSegment3D >::const_reverse_iterator const_reverse_iterator
GLubyte GLubyte GLubyte GLubyte w
A renderizable object suitable for rendering with OpenGL's display lists.
#define ASSERT_(f)
Defines an assertion mechanism.
std::vector< mrpt::math::TSegment3D >::iterator iterator
float getLineWidth() const
Gets the width with which lines are drawn.
void appendLine(const mrpt::math::TSegment3D &sgm)
Appends a line to the set.
float getVerticesPointSize() const
3D segment, consisting of two points.
void getBoundingBox(mrpt::math::TPoint3D &bb_min, mrpt::math::TPoint3D &bb_max) const override
Evaluates the bounding box of this object (including possible children) in the coordinate frame of th...
void reserve(size_t r)
Reserves an amount of lines to the set.
void setVerticesPointSize(const float size_points)
Enable showing vertices as dots if size_points>0.
void clear()
Clear the list of segments.
void render_dl() const override
Render.
const_reverse_iterator rbegin() const
Beginning const reverse iterator (actually, accesses the end of the set).
#define DEFINE_SERIALIZABLE(class_name)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
CSetOfLines()
Constructor.
std::vector< mrpt::math::TSegment3D >::reverse_iterator reverse_iterator
GLdouble GLdouble GLdouble r
const_reverse_iterator rend() const
Ending const reverse iterator (actually, refers to the starting point of the set).
The namespace for 3D scene representation and rendering.
std::vector< mrpt::math::TSegment3D >::const_iterator const_iterator
bool isAntiAliasingEnabled() const
void appendLine(T p0, U p1)
Inserts a line, given its bounds.
bool empty() const
Returns true if there are no line segments.
A set of independent lines (or segments), one line with its own start and end positions (X...
void appendLines(const T_it &begin, const T_it &end)
Appends certain amount of lines, located between two iterators, into the set.
~CSetOfLines() override=default
Private, virtual destructor: only can be deleted from smart pointers.
void appendLine(float x0, float y0, float z0, float x1, float y1, float z1)
Appends a line to the set, given the coordinates of its bounds.
void setLineByIndex(size_t index, const mrpt::math::TSegment3D &segm)
Sets a specific line in the set, given its index.
void appendLineStrip(const U &point)