class mrpt::viz::CSimpleLine
Overview
A line segment.
See also:
opengl::Scene
#include <mrpt/viz/CSimpleLine.h> class CSimpleLine: public mrpt::viz::CVisualObject, public mrpt::viz::VisualObjectParams_Lines { public: // typedefs typedef std::shared_ptr<mrpt::viz ::CSimpleLine> Ptr; typedef std::shared_ptr<const mrpt::viz ::CSimpleLine> ConstPtr; typedef std::unique_ptr<mrpt::viz ::CSimpleLine> UniquePtr; typedef std::unique_ptr<const mrpt::viz ::CSimpleLine> ConstUniquePtr; // fields static constexpr const char* className = "mrpt::viz" "::" "CSimpleLine"; // construction CSimpleLine( float x0 = 0, float y0 = 0, float z0 = 0, float x1 = 0, float y1 = 0, float z1 = 0, float lineWidth = 1, bool antiAliasing = true ); // methods static constexpr auto getClassName(); static const mrpt::rtti::TRuntimeClassId& GetRuntimeClassIdStatic(); static std::shared_ptr<CObject> CreateObject(); template <typename... Args> static Ptr Create(Args&&... args); template <typename Alloc, typename... Args> static Ptr CreateAlloc( const Alloc& alloc, Args&&... args ); template <typename... Args> static UniquePtr CreateUnique(Args&&... args); virtual const mrpt::rtti::TRuntimeClassId* GetRuntimeClass() const; virtual mrpt::rtti::CObject* clone() const; void setLineCoords( const mrpt::math::TPoint3Df& p0, const mrpt::math::TPoint3Df& p1 ); mrpt::math::TPoint3Df getLineStart() const; mrpt::math::TPoint3Df getLineEnd() const; void setLineCoords(float x0, float y0, float z0, float x1, float y1, float z1); void getLineCoords(float& x0, float& y0, float& z0, float& x1, float& y1, float& z1) const; virtual mrpt::math::TBoundingBoxf internalBoundingBoxLocal() const; };
Inherited Members
public: // typedefs typedef std::shared_ptr<CObject> Ptr; typedef std::shared_ptr<const CObject> ConstPtr; typedef std::shared_ptr<CSerializable> Ptr; typedef std::shared_ptr<const CSerializable> ConstPtr; // structs struct PoseAndScale; struct State; // methods static const mrpt::rtti::TRuntimeClassId& GetRuntimeClassIdStatic(); virtual const mrpt::rtti::TRuntimeClassId* GetRuntimeClass() const; virtual const mrpt::rtti::TRuntimeClassId* GetRuntimeClass() const; static const mrpt::rtti::TRuntimeClassId& GetRuntimeClassIdStatic(); virtual const mrpt::rtti::TRuntimeClassId* GetRuntimeClass() const; const auto& shaderLinesVertexPointBuffer() const; const auto& shaderLinesVertexColorBuffer() const; auto& shaderLinesBufferMutex() const; void setLineWidth(float w); float getLineWidth() const; void enableAntiAliasing(bool enable = true); bool isAntiAliasingEnabled() const;
Typedefs
typedef std::shared_ptr<mrpt::viz ::CSimpleLine> Ptr
A type for the associated smart pointer.
Construction
CSimpleLine( float x0 = 0, float y0 = 0, float z0 = 0, float x1 = 0, float y1 = 0, float z1 = 0, float lineWidth = 1, bool antiAliasing = true )
Constructor.
Methods
virtual const mrpt::rtti::TRuntimeClassId* GetRuntimeClass() const
Returns information about the class of an object in runtime.
virtual mrpt::rtti::CObject* clone() const
Returns a deep copy (clone) of the object, indepently of its class.
void setLineCoords(float x0, float y0, float z0, float x1, float y1, float z1)
Deprecated (MRPT 2.3.1)
void getLineCoords( float& x0, float& y0, float& z0, float& x1, float& y1, float& z1 ) const
Deprecated (MRPT 2.3.1)
virtual mrpt::math::TBoundingBoxf internalBoundingBoxLocal() const
Must be implemented by derived classes to provide the updated bounding box in the object local frame of coordinates.
This will be called only once after each time the derived class reports to notifyChange() that the object geometry changed.
See also:
getBoundingBox(), getBoundingBoxLocal(), getBoundingBoxLocalf()