class mrpt::opengl::CDisk

A planar disk in the XY plane.

mrpt::opengl::CDisk

See also:

opengl::COpenGLScene

#include <mrpt/opengl/CDisk.h>

class CDisk: public mrpt::opengl::CRenderizableShaderTriangles
{
public:
    // construction

    CDisk();

    CDisk(
        float rOut,
        float rIn,
        uint32_t slices = 50
        );

    //
methods

    virtual void onUpdateBuffers_Triangles();

    void setDiskRadius(
        float outRadius,
        float inRadius = 0
        );

    float getInRadius() const;
    float getOutRadius() const;
    void setSlicesCount(uint32_t N);
    virtual mrpt::math::TBoundingBox getBoundingBox() const;
    virtual bool traceRay(const mrpt::poses::CPose3D& o, double& dist) const;
};

Inherited Members

public:
    // structs

    struct RenderContext;

    //
methods

    virtual void render(const RenderContext& rc) const = 0;
    virtual void renderUpdateBuffers() const = 0;
    virtual shader_list_t requiredShaders() const;
    virtual auto getBoundingBox() const = 0;
    virtual void freeOpenGLResources() = 0;
    virtual void onUpdateBuffers_Triangles() = 0;

Construction

CDisk()

Constructor.

Methods

virtual void onUpdateBuffers_Triangles()

Must be implemented in derived classes to update the geometric entities to be drawn in “m_*_buffer” fields.

void setSlicesCount(uint32_t N)

Default=50.

virtual mrpt::math::TBoundingBox getBoundingBox() const

Evaluates the bounding box of this object (including possible children) in the coordinate frame of the object parent.

virtual bool traceRay(const mrpt::poses::CPose3D& o, double& dist) const

Ray tracing.