|
Visualizer for voxel grids of with voxel type VoxelT. More...
#include <VisionX/libraries/VoxelGridCore/Visualizer.hpp>
Classes | |
struct | VoxelVisuData |
Information about a voxel about to-be-drawn. More... | |
Public Member Functions | |
void | clearLayer () |
Clear the layer. More... | |
void | clearVoxelLayer (bool sleep=false) |
Clear the voxel layer. More... | |
void | draw (const VoxelGrid< VoxelT > &grid) |
Draw the voxel grid. More... | |
void | drawBoundingEdges (const VoxelGrid< VoxelT > &grid) |
Draw the bounding edges of the voxel grid. More... | |
void | drawStructure (const VoxelGrid< VoxelT > &grid, float lineWidth=1, const armarx::DrawColor &colorEdges={0,.5, 1, 1}, const armarx::DrawColor &colorStructure={0, 1, 1, 1}, bool drawOriginVoxel=false) |
Draw the bounding edges of the voxel grid. More... | |
operator bool () const | |
void | setDebugDrawer (const armarx::DebugDrawerInterfacePrx &debugDrawer) |
Set the debug drawer. More... | |
void | setLayer (const std::string &layer) |
Set the layer name. More... | |
Visualizer () | |
Default constructor. More... | |
Visualizer (const armarx::DebugDrawerTopic &drawer, const std::string &voxelLayer="VoxelGrid") | |
Initialize with debug drawer and voxel grid. More... | |
virtual | ~Visualizer () |
Virtual destructor. More... | |
Protected Member Functions | |
armarx::DebugDrawerTopic & | drawer () |
Get the debug drawer. More... | |
const armarx::DebugDrawerTopic & | drawer () const |
virtual void | drawVoxel (const VoxelVisuData &visu) |
Draw a voxel. More... | |
std::string | getVoxelLayer () const |
Get the layer name. More... | |
virtual bool | isVisible (const VoxelVisuData &visu) const |
Indicate whether a voxel shall be drawn. More... | |
Visualizer for voxel grids of with voxel type VoxelT.
Definition at line 44 of file Visualizer.hpp.
Default constructor.
Definition at line 154 of file Visualizer.hpp.
Visualizer | ( | const armarx::DebugDrawerTopic & | drawer, |
const std::string & | voxelLayer = "VoxelGrid" |
||
) |
Initialize with debug drawer and voxel grid.
Definition at line 158 of file Visualizer.hpp.
|
inlinevirtual |
Virtual destructor.
Reimplemented in Visualizer, and Visualizer.
Definition at line 54 of file Visualizer.hpp.
void clearLayer |
Clear the layer.
Definition at line 168 of file Visualizer.hpp.
void clearVoxelLayer | ( | bool | sleep = false | ) |
Clear the voxel layer.
Definition at line 174 of file Visualizer.hpp.
void draw | ( | const VoxelGrid< VoxelT > & | grid | ) |
Draw the voxel grid.
Definition at line 394 of file Visualizer.hpp.
void drawBoundingEdges | ( | const VoxelGrid< VoxelT > & | grid | ) |
Draw the bounding edges of the voxel grid.
Definition at line 180 of file Visualizer.hpp.
|
inlineprotected |
Get the debug drawer.
Definition at line 122 of file Visualizer.hpp.
|
inlineprotected |
Definition at line 126 of file Visualizer.hpp.
void drawStructure | ( | const VoxelGrid< VoxelT > & | grid, |
float | lineWidth = 1 , |
||
const armarx::DrawColor & | colorEdges = {0, .5, 1, 1} , |
||
const armarx::DrawColor & | colorStructure = {0, 1, 1, 1} , |
||
bool | drawOriginVoxel = false |
||
) |
Draw the bounding edges of the voxel grid.
Definition at line 241 of file Visualizer.hpp.
|
protectedvirtual |
Draw a voxel.
Reimplemented in Visualizer, and Visualizer.
Definition at line 417 of file Visualizer.hpp.
|
inlineprotected |
Get the layer name.
Definition at line 132 of file Visualizer.hpp.
|
inlineprotectedvirtual |
Indicate whether a voxel shall be drawn.
Voxels for which this method returns false are not passed to drawVoxel().
Reimplemented in Visualizer, and Visualizer.
Definition at line 112 of file Visualizer.hpp.
|
inline |
Definition at line 87 of file Visualizer.hpp.
|
inline |
Set the debug drawer.
Definition at line 77 of file Visualizer.hpp.
|
inline |
Set the layer name.
Definition at line 82 of file Visualizer.hpp.