Simox
2.3.74.0
|
Public Member Functions | |
VisualizationNode (const TriMeshModelPtr &triMeshModel=nullptr) | |
VisualizationNode (const TriMeshModel &triMeshModel) | |
virtual | ~VisualizationNode () |
virtual TriMeshModelPtr | getTriMeshModel () |
virtual void | setGlobalPose (const Eigen::Matrix4f &m) |
const Eigen::Matrix4f & | getGlobalPose () const |
virtual VisualizationNodePtr | clone (bool deepCopy=true, float scaling=1.0f) |
virtual void | attachVisualization (const std::string &name, VisualizationNodePtr v) |
virtual void | detachVisualization (const std::string &name) |
virtual bool | hasAttachedVisualization (const std::string &name) |
virtual VisualizationNodePtr | getAttachedVisualization (const std::string &name) |
virtual void | setupVisualization (bool showVisualization, bool showAttachedVisualizations) |
void | setUpdateVisualization (bool enable) |
bool | getUpdateVisualizationStatus () |
virtual void | print () |
print information about this visualization object. More... | |
virtual int | getNumFaces () |
get number of faces (i.e. triangles) of this object More... | |
std::string | getFilename () |
optional filename tag More... | |
bool | usedBoundingBoxVisu () |
void | setFilename (const std::string &filename, bool boundingBox) |
Just stores the filename, no loading is performed! More... | |
virtual std::string | getType () |
std::string | toXML (const std::string &basePath, int tabs) |
std::string | toXML (const std::string &basePath, const std::string &filename, int tabs) |
BoundingBox | getBoundingBox () |
virtual bool | saveModel (const std::string &modelPath, const std::string &filename) |
virtual void | scale (const Eigen::Vector3f &scaleFactor) |
virtual void | scale (float scaleFactor) |
virtual void | shrinkFatten (float offset) |
virtual void | createTriMeshModel () |
update trimesh model More... | |
Static Public Member Functions | |
static VisualizationNodePtr | CreateUnitedVisualization (const std::vector< VisualizationNodePtr > &visualizations) |
Data Fields | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW std::vector< Primitive::PrimitivePtr > | primitives |
Protected Attributes | |
bool | boundingBox |
Indicates, if the bounding box model was used. More... | |
std::string | filename |
if the visualization was build from a file, the filename is stored here More... | |
Eigen::Matrix4f | globalPose |
bool | updateVisualization |
bool | showVisualization |
bool | showAttachedVisualizations |
TriMeshModelPtr | triMeshModel |
std::map< std::string, VisualizationNodePtr > | attachedVisualizations |
VirtualRobot::VisualizationNode::VisualizationNode | ( | const TriMeshModelPtr & | triMeshModel = nullptr | ) |
Constructor
VirtualRobot::VisualizationNode::VisualizationNode | ( | const TriMeshModel & | triMeshModel | ) |
|
virtual |
|
virtual |
Attach an optional visualization to this VisualizationNode. The attached visualizations will not show up in the TriMeshModel. If there is already a visualization attached with the given name, it is quietly replaced.
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
Clone this visualization.
deepCopy | When true, the underlying visualization is copied, otherwise a reference to the existing visualization is passed. |
scaling | Scale Can be set to create a scaled version of this visual data. Since the underlying implementation may be able to re-use the visualization data, a deep copy may not be necessary in some cases. |
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
update trimesh model
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
static |
Create a united visualization. Behavior depends on the derived implementation, but usually the visualizations are copied and united to one object.
|
virtual |
Remove an attached visualization.
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
Get for an attached visualization.
VirtualRobot::BoundingBox VirtualRobot::VisualizationNode::getBoundingBox | ( | ) |
Returns (current) bounding box in global coordinate system.
std::string VirtualRobot::VisualizationNode::getFilename | ( | ) |
optional filename tag
|
inline |
|
virtual |
get number of faces (i.e. triangles) of this object
|
virtual |
Creates a triangulated model.
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
inlinevirtual |
Reimplemented in VirtualRobot::CoinVisualizationNode.
bool VirtualRobot::VisualizationNode::getUpdateVisualizationStatus | ( | ) |
|
virtual |
Check for an attached visualization.
|
virtual |
print information about this visualization object.
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
Saves model file to model path.
modelPath | The directory. |
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
void VirtualRobot::VisualizationNode::setFilename | ( | const std::string & | filename, |
bool | boundingBox | ||
) |
Just stores the filename, no loading is performed!
|
inlinevirtual |
Sets the position of the internal data structure.
Reimplemented in VirtualRobot::CoinVisualizationNode.
void VirtualRobot::VisualizationNode::setUpdateVisualization | ( | bool | enable | ) |
Enables/Disables the visualization updates. Usually if a SceneObject or a RobotNode changes its state, the visualization is automatically updated. This behavior can be changed here.
|
virtual |
Setup the visualization of this object.
showVisualization | If false, the visualization is disabled. |
showAttachedVisualizations | If false, the visualization of any attached optional visualizations is disabled. |
Reimplemented in VirtualRobot::CoinVisualizationNode.
|
virtual |
Reimplemented in VirtualRobot::CoinVisualizationNode.
std::string VirtualRobot::VisualizationNode::toXML | ( | const std::string & | basePath, |
int | tabs | ||
) |
std::string VirtualRobot::VisualizationNode::toXML | ( | const std::string & | basePath, |
const std::string & | filename, | ||
int | tabs | ||
) |
Ctreate XML string and replace filename
bool VirtualRobot::VisualizationNode::usedBoundingBoxVisu | ( | ) |
|
protected |
|
protected |
Indicates, if the bounding box model was used.
|
protected |
if the visualization was build from a file, the filename is stored here
|
protected |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW std::vector<Primitive::PrimitivePtr> VirtualRobot::VisualizationNode::primitives |
|
protected |
|
protected |
|
protected |
|
protected |