Scene Rendering
A scene is rendered in the following three steps.
Determining the viewing transformation
If viewing from a scene tree Camera node is desired, a
pruned traversal of the scene tree takes place to determine the
viewing transformation that emulates this camera's point of
view. During this traversal, all nodes are ignored except for
- Group nodes,
- Joint Transformation nodes,
- Static Transformation nodes, and
- the specified Camera node.
If viewing from the default camera is desired, the following viewpoint
parameters are used:
- The scene is rendered from the origin's point of view.
- -z is the viewing direction.
- +y points upwards.
- The vertical field of view is 50 degrees.
- The near and far clipping planes are at z=-1 and z=-20.
Turning on the lights
Iff the user has specified that the scene primitives be rendered as lit solids, the
scene tree is traversed in order to enable and configure all OpenGL lights in the
scene. If any OpenGL ID is used
twice, a warning is issued, as the former usage is fully overridden by
the latter. During this traversal, all nodes are ignored except for
- Group nodes,
- Joint Transformation nodes,
- Static Transformation nodes, and
- Light nodes.
Rendering the objects
The scene tree is traversed one final time in order to render all
objects in the scene. During this traversal, all nodes are ignored
except for
- Group nodes,
- Joint Transformation nodes,
- Static Transformation nodes,
- Material nodes, and
- Light nodes.
Last update: 16 April 1996
by Apostolos "Toli" Lerios