A SERVICE OF

logo

Scene Graph Construction Classes
7
Scene Graph Construction Classes
This section discusses several essential elements of a scene graph.These elements are part
of most scene graphs and make it possible for the geometry elements of a model to be
drawn and to relate to one another.
Figure 1-1 shows a basic scene graph similar to the example program discussed in
Appendix B, Cosmo 3D Sample Application. Black lines indicate parent-child
relationships; gray lines indicate class-eld links.
The gure shows the following elements, which are discussed in this section:
•“The csGroup Class”—allows you to group csNodes.
•“The csTransform Class”—applies a transformation, such as rotation, scaling, to all
its children.
•“The csShape Class”—encapsulates a geometric shape; providing appearance and
geometry elds and a draw() method.
•“The csAppearance Class”—contains elds to specify the material properties of a
surface, including transparency, color, and texture.
•“The csGeometry Class”—encapsulates the geometric data to which a
csAppearance can be applied.