Menge
Modular Pedestrian Simulation Framework for Research and Development
|
The node that provides the basis for a "hierarchy" in the scene graph. More...
#include <GLNode.h>
Public Member Functions | |
GLDagNode (GLDagNode *parent=0x0) | |
Constructor. More... | |
virtual | ~GLDagNode () |
Virtual destructor. | |
void | addChild (GLNode *child) |
Adds a child node to this node. More... | |
virtual void | newContext () |
Performs any work to recreate OpenGL constructs for this node and its children nodes. | |
virtual void | drawGL (bool select=false) |
Causes this node's child nodes to draw themselves to the scene. More... | |
virtual void | getMatrix (Matrix4x4 &mat) |
Reports the local object transform matrix. More... | |
virtual void | getInverseMatrix (Matrix4x4 &mat) |
Reports the local object inverse transform matrix. More... | |
virtual void | getWorldMatrix (Matrix4x4 &mat) |
Reports the world object transform matrix. More... | |
virtual void | getWorldInverseMatrix (Matrix4x4 &mat) |
Reports the world object inverse transform matrix. More... | |
virtual void | getParentMatrix (Matrix4x4 &mat) |
The world matrix of this node's parent matrix (see GLDagNode::getWorldMatrix) More... | |
virtual void | getParentInverseMatrix (Matrix4x4 &mat) |
The inverse world matrix of this node's parent matrix (see GLDagNode::getWorldInverseMatrix) More... | |
Public Member Functions inherited from Menge::SceneGraph::GLNode | |
GLNode (GLDagNode *parent=0x0) | |
Constructor. More... | |
virtual | ~GLNode () |
Virtual destructor. | |
void | setVisible (bool state) |
Sets the visible state of the node. More... | |
GLDagNode * | getParent () |
Returns a pointer to the node's parent (possibly NULL). More... | |
Protected Attributes | |
GLNode ** | _children |
An array of child GLNodes. | |
size_t | _childCount |
The number of child nodes this node contains. | |
Protected Attributes inherited from Menge::SceneGraph::GLNode | |
GLDagNode * | _parent |
The GLDagNode that serves as this node's parent. | |
bool | _visible |
The visibility state of this node. If visible (true) the node and its children will be drawn into the scene, if invisible (false) it will not be drawn. | |
Additional Inherited Members | |
Protected Member Functions inherited from Menge::SceneGraph::GLNode | |
void | setParent (GLDagNode *p) |
Assigns this node to a parent GLDagNode. More... | |
The node that provides the basis for a "hierarchy" in the scene graph.
The scene graph is, ultimately, not truly a graph. It is a directed acyclic graph, best thought of as a tree with the GLScene at the root and all other nodes inserted into sub-strees below the GLScene.
The GLDagNode serves as the basis for this. It is a GLNode that can accept children, providing the mechanism for creating trees
Menge::SceneGraph::GLDagNode::GLDagNode | ( | GLDagNode * | parent = 0x0 | ) |
Constructor.
parent | A pointer to the optional parent node in the graph. |
void Menge::SceneGraph::GLDagNode::addChild | ( | GLNode * | child | ) |
Adds a child node to this node.
Nodes can be linked either by calling GLNode::setParent or GLDagNode::addChild
child | The node to add as a child to this node. |
|
virtual |
Causes this node's child nodes to draw themselves to the scene.
select | Determines if the draw call is being performed for the purpose of selection (true) or for visualization (false). |
Implements Menge::SceneGraph::GLNode.
Reimplemented in Menge::SceneGraph::Transform.
|
inlinevirtual |
Reports the local object inverse transform matrix.
By definition, because this node can provide no transformation its inverse transform matrix is the identity matrix.
mat | The 4x4 matrix into which the identity matrix is set. |
Reimplemented in Menge::SceneGraph::Transform.
|
inlinevirtual |
Reports the local object transform matrix.
By definition, because this node can provide no transformation its transform matrix is the identity matrix.
mat | The 4x4 matrix into which the identity matrix is set. |
Reimplemented in Menge::SceneGraph::Transform.
|
virtual |
The inverse world matrix of this node's parent matrix (see GLDagNode::getWorldInverseMatrix)
mat | The 4x4 matrix into which the result is written. If this node has no parent matrix, the identity matrix is stored. |
Reimplemented in Menge::SceneGraph::Transform.
|
virtual |
The world matrix of this node's parent matrix (see GLDagNode::getWorldMatrix)
mat | The 4x4 matrix into which the result is written. If this node has no parent matrix, the identity matrix is stored. |
Reimplemented in Menge::SceneGraph::Transform.
|
virtual |
Reports the world object inverse transform matrix.
This is the concatenation of all transforms experienced by this node and any node in its ancestors up to the GLSCene. This is essentially the transform that transforms elements in world space into this object's space.
mat | The 4x4 matrix into which the inverse world matrix is set. |
Reimplemented in Menge::SceneGraph::Transform.
|
virtual |
Reports the world object transform matrix.
This is the concatenation of all transforms experienced by this node and any node in its ancestors up to the GLSCene. This is essentially the transform that transforms elements in this object's space into world space.
mat | The 4x4 matrix into which the world matrix is set. |
Reimplemented in Menge::SceneGraph::Transform.