class mrpt::opengl::Visualizable

Overview

Interface for classes visualizable as an mrpt::opengl::CSetOfObjects.

#include <mrpt/opengl/Visualizable.h>

class Visualizable
{
public:
    // construction

    Visualizable();

    // methods

    virtual void getVisualizationInto(mrpt::opengl::CSetOfObjects& o) const = 0;
    std::shared_ptr<mrpt::opengl::CSetOfObjects> getVisualization() const;
};

Methods

virtual void getVisualizationInto(mrpt::opengl::CSetOfObjects& o) const = 0

Inserts 3D primitives representing this object into the provided container.

Note that the former contents of o are not cleared.

See also:

getVisualization()

std::shared_ptr<mrpt::opengl::CSetOfObjects> getVisualization() const

Creates 3D primitives representing this objects.

This is equivalent to getVisualizationInto() but creating, and returning by value, a new rpt::opengl::CSetOfObjects::Ptr shared pointer.

See also:

getVisualizationInto()