77 void loadScene(
const std::string& file_name);
void freeOpenGLResources() override
Free opengl buffers.
void freeOpenGLResources() override
Free opengl buffers.
void onUpdateBuffers_all()
void onUpdateBuffers_Triangles() override
Must be implemented in derived classes to update the geometric entities to be drawn in "m_*_buffer" f...
void onUpdateBuffers_Points() override
Must be implemented in derived classes to update the geometric entities to be drawn in "m_*_buffer" f...
Renderizable generic renderer for objects using the triangles shader.
void freeOpenGLResources() override
Free opengl buffers.
void loadScene(const std::string &file_name)
Loads a scene from a file in any supported file.
mrpt::math::TPoint3D m_bbox_min
Bounding box.
std::vector< shader_id_t > shader_list_t
A list of shader IDs.
bool traceRay(const mrpt::poses::CPose3D &o, double &dist) const override
Simulation of ray-trace, given a pose.
Context for calls to render()
void onUpdateBuffers_Wireframe() override
Must be implemented in derived classes to update the geometric entities to be drawn in "m_*_buffer" f...
mrpt::math::TPoint3D m_bbox_max
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 clear()
Empty the object.
static constexpr shader_id_t WIREFRAME
virtual ~CAssimpModel() override
void renderUpdateBuffers() const override
Called whenever m_outdatedBuffers is true: used to re-generate OpenGL vertex buffers, etc.
Renderizable generic renderer for objects using the points shader.
static constexpr shader_id_t TRIANGLES
void render(const RenderContext &rc) const override
Implements the rendering of 3D objects in each class derived from CRenderizable.
A class used to store a 3D pose (a 3D translation + a rotation in 3D).
Renderizable generic renderer for objects using the wireframe shader.
The namespace for 3D scene representation and rendering.
#define DEFINE_SERIALIZABLE(class_name, NS)
This declaration must be inserted in all CSerializable classes definition, within the class declarati...
void freeOpenGLResources() override
Free opengl buffers.
virtual shader_list_t requiredShaders() const override
Returns the ID of the OpenGL shader program required to render this class.
A container for automatic deletion of assimp scene when the last reference of the smart_ptr's is dest...
This class can load & render 3D models in a number of different formats (requires the library assimp)...
static constexpr shader_id_t POINTS
std::shared_ptr< TImplAssimp > m_assimp_scene