Core Scene Graph Data Structures in C++
Node
The Node C++ class is the base class for all the scene graph nodes in the DGP2023 implementation. This is an abstract class which does not correspond to any scene graph node, but it is used to store information common to all the nodes, such as a node name.
The following classes are subclasses of Node: Group, Shape, Appearance, Material, PixelTexture, IndexedFaceSet, and IndexedLineSet.
The following classes are subclasses of the Group class: Transform, and SceneGraph.
The ImageTexture class is subclass of the PixelTexture class.
This is the public interface to the Node class:
class Node { public: Node(); virtual ~Node(); const string& getName() const; void setName(const string& name); bool nameEquals(const string& name); const Node* getParent() const; void setParent(const Node* node); bool getShow() const; void setShow(const bool value); int getDepth() const; virtual bool isAppearance() const; virtual bool isGroup() const; virtual bool isImageTexture() const; virtual bool isIndexedFaceSet() const; virtual bool isIndexedLineSet() const; virtual bool isMaterial() const; virtual bool isPixelTexture() const; virtual bool isSceneGraph() const; virtual bool isShape() const; virtual bool isTransform() const; virtual string getType() const; };