HIRO_DRAW
Computer Graphics Structures library
hiro::draw::PointCloudRenderer Class Reference

Renderer used for rendering point clouds. More...

Inheritance diagram for hiro::draw::PointCloudRenderer:
[legend]

Public Member Functions

 PointCloudRenderer ()=default
 Creates a renderer without point cloud.
 
 PointCloudRenderer (const cogs::PointCloud &pc)
 Creates a renderer with the specified point cloud.
 
 PointCloudRenderer (const hiro::draw::PointCloudRenderer &source)=delete
 
PointCloudRenderer & operator= (const hiro::draw::PointCloudRenderer &source)=delete
 
 PointCloudRenderer (hiro::draw::PointCloudRenderer &&) noexcept=delete
 
PointCloudRenderer & operator= (hiro::draw::PointCloudRenderer &&) noexcept=delete
 
void Reset (const cogs::PointCloud &pc)
 Replaces currently set point cloud with a new one.
 
size_t GetPointCount () const
 Returns number of points in the rendered pointcloud.
 
void SetColors (const std::vector< cogs::Color3f > &colors)
 Set custom color for each point.
 
virtual bool IsCompatibileWithStyle (const hiro::draw::Style *style) override
 Test whether specified style is compatible with the object.
 
- Public Member Functions inherited from hiro::draw::ElementRenderer
 ElementRenderer (const hiro::draw::ElementRenderer &source)=delete
 
ElementRenderer & operator= (const hiro::draw::ElementRenderer &source)=delete
 
 ElementRenderer (hiro::draw::ElementRenderer &&) noexcept=delete
 
ElementRenderer & operator= (hiro::draw::ElementRenderer &&) noexcept=delete
 

Protected Member Functions

virtual void OnRenderPoints () override
 Defines behavior on point rendering.
 
virtual void OnRenderNormals () override
 Defines behavior on normal rendering.
 
- Protected Member Functions inherited from hiro::draw::ElementRenderer
 ElementRenderer ()
 Protected constructor, since this class should serve only as a base class.
 
void LoadRequiredShaderPrograms (glw::ProgramList *programs) override
 Loads shader programs required by this renderer.
 
void Render (const std::string &program) override
 Specifies what happens during render.
 
virtual void OnRenderFaces ()
 Override if you wish to render faces. Use the method RenderFaces to actually render.
 
void RenderPoints (const hiro::draw::PointsStyle &style, std::function< void(void)> render_func)
 Prepares shader according to the style and renders points using the specified render_func.
 
void RenderFaces (const hiro::draw::FacesStyle &style, std::function< void(void)> render_func)
 Prepares shader according to the style and renders faces using the specified render_func.
 
void RenderNormals (const hiro::draw::NormalsStyle &style, std::function< void(void)> render_func)
 Prepares shader according to the style and renders normals using the specified render_func.
 
- Protected Member Functions inherited from hiro::draw::Renderer
virtual void OnRenderSimple ()
 Provides the possibility to render shapes using a simple color shader. More...
 
virtual void Render2D (const std::string &program)
 Override this method to specify custom rendering behavior in 2D rendering pass.
 
virtual void OnRenderSimple2D ()
 Provides the possibility to render shapes using a simple color shader. More...
 
virtual void FillTextRenderer (hiro::draw::TextRenderer *t_renderer)
 Override this method to define texts to be rendered.
 
template<typename StyleType >
const StyleType * GetStyle () const
 Obtain currently set object style of specific type. Can be used only in Update-Render stage!
 
const Scene * GetScene () const
 

Detailed Description

Renderer used for rendering point clouds.