Simox
2.3.74.0
|
Public Member Functions | |
CoinVisualizationNode (const TriMeshModelPtr &tri) | |
CoinVisualizationNode (const TriMeshModel &tri) | |
CoinVisualizationNode (SoNode *visualizationNode, float margin=0.0f) | |
~CoinVisualizationNode () override | |
TriMeshModelPtr | getTriMeshModel () override |
SoNode * | getCoinVisualization () |
void | setGlobalPose (const Eigen::Matrix4f &m) override |
void | print () override |
print information about this visualization object. More... | |
void | scale (const Eigen::Vector3f &scaleFactor) override |
void | attachVisualization (const std::string &name, VisualizationNodePtr v) override |
void | detachVisualization (const std::string &name) override |
void | setupVisualization (bool showVisualization, bool showAttachedVisualizations) override |
VisualizationNodePtr | clone (bool deepCopy=true, float scaling=1.0f) override |
std::string | getType () override |
bool | saveModel (const std::string &modelPath, const std::string &filename) override |
void | shrinkFatten (float offset) override |
void | createTriMeshModel () override |
Public Member Functions inherited from VirtualRobot::VisualizationNode | |
VisualizationNode (const TriMeshModelPtr &triMeshModel=nullptr) | |
VisualizationNode (const TriMeshModel &triMeshModel) | |
virtual | ~VisualizationNode () |
const Eigen::Matrix4f & | getGlobalPose () const |
virtual bool | hasAttachedVisualization (const std::string &name) |
virtual VisualizationNodePtr | getAttachedVisualization (const std::string &name) |
void | setUpdateVisualization (bool enable) |
bool | getUpdateVisualizationStatus () |
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... | |
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 void | scale (float scaleFactor) |
Protected Member Functions | |
void | setVisualization (SoNode *newVisu) |
Static Protected Member Functions | |
static void | InventorTriangleCB (void *data, SoCallbackAction *action, const SoPrimitiveVertex *v1, const SoPrimitiveVertex *v2, const SoPrimitiveVertex *v3) |
Protected Attributes | |
SoNode * | visualization |
SoSeparator * | visualizationAtGlobalPose |
SoSeparator * | attachedVisualizationsSeparator |
SoSeparator * | scaledVisualization |
std::map< std::string, SoNode *> | attachedCoinVisualizations |
SoMatrixTransform * | globalPoseTransform |
SoScale * | scaling |
float | margin = 0.0f |
Protected Attributes inherited from VirtualRobot::VisualizationNode | |
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 |
Friends | |
class | CoinVisualizationFactory |
Additional Inherited Members | |
Static Public Member Functions inherited from VirtualRobot::VisualizationNode | |
static VisualizationNodePtr | CreateUnitedVisualization (const std::vector< VisualizationNodePtr > &visualizations) |
Data Fields inherited from VirtualRobot::VisualizationNode | |
EIGEN_MAKE_ALIGNED_OPERATOR_NEW std::vector< Primitive::PrimitivePtr > | primitives |
VirtualRobot::CoinVisualizationNode::CoinVisualizationNode | ( | const TriMeshModelPtr & | tri | ) |
VirtualRobot::CoinVisualizationNode::CoinVisualizationNode | ( | const TriMeshModel & | tri | ) |
VirtualRobot::CoinVisualizationNode::CoinVisualizationNode | ( | SoNode * | visualizationNode, |
float | margin = 0.0f |
||
) |
Store a reference to visualizationNode
in the member CoinVisualizationNode::visualization. If visualizationNode
is a valid object call SoNode::ref() on it.
|
override |
If CoinVisualizationNode::visualization is a valid object call SoNode::unref() on it.
|
overridevirtual |
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 from VirtualRobot::VisualizationNode.
|
overridevirtual |
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 from VirtualRobot::VisualizationNode.
|
overridevirtual |
This method constructs an instance of TriMeshModel and stores it in CoinVisualizationNode::triMeshModel. If CoinVisualizationMode::visualization is invalid VirtualRobotException is thrown. Otherwise CoinVisualizationNode::InventorTriangleCB() is called on the Inventor graph stored in CoinVisualizationNode::visualization.
Reimplemented from VirtualRobot::VisualizationNode.
|
overridevirtual |
Remove an attached visualization.
Reimplemented from VirtualRobot::VisualizationNode.
SoNode * VirtualRobot::CoinVisualizationNode::getCoinVisualization | ( | ) |
This mehtod returns the internal CoinVisualizationNode::visualization.
|
overridevirtual |
This method returns CoinVisualizationNode::triMeshModel. If the model doesn't exist construct it by calling CoinVisualizationNode::createTriMeshModel().
Reimplemented from VirtualRobot::VisualizationNode.
|
inlineoverridevirtual |
Reimplemented from VirtualRobot::VisualizationNode.
|
staticprotected |
This method extracts the triangle given by v1
, v2
, v3
and stores it in the TriMeshModel instance passed in through data
by calling TriMeshModel::addTriangleWithFace() with the extracted triangle.
|
overridevirtual |
print information about this visualization object.
Reimplemented from VirtualRobot::VisualizationNode.
|
overridevirtual |
Saves model file to model path. By default VRML models are generated.
modelPath | The directory. |
filename | The new filename. If filename extension is ".iv", the file is stored in Open Inventor format. Otherwise the file is stored in VRML2 format (.wrl). |
Reimplemented from VirtualRobot::VisualizationNode.
|
overridevirtual |
Reimplemented from VirtualRobot::VisualizationNode.
|
overridevirtual |
Sets the position of the internal data structure.
Reimplemented from VirtualRobot::VisualizationNode.
|
overridevirtual |
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 from VirtualRobot::VisualizationNode.
|
protected |
Replace current visualization of this node. Be careful: any former grabbed trimeshmodels do no longer represent the new datastructure!
|
overridevirtual |
Reimplemented from VirtualRobot::VisualizationNode.
|
friend |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |
|
protected |