Unlike real-time rasterizing libraries such as OpenGL whose
only purpose is render the raw data passed to them, NuGraf performs many more functions
such as maintaining the 3D scene database, rendering the scene using more advanced
algorithms and outputting the scanline data to various file formats and video devices.
Since NuGraf has its own built-in database manager, a scene is
rendered by first sending all of the scene elements and related attributes to the database
manager. Once the scene is specified the database manager breaks each element down into
polygons and sends them to the internal scanline renderer. The output of the renderer is
sent to a custom output driver, one scanline at a time. Note that unlike OpenGL,
the scene does not have to be redefined after each rendering; rather, the scene remains
static within the database manager until it is modified by the host application. Thus,
powerful features such as the modification, query or update of the database can be
off-loaded to the toolkit rather than require the host application to perform these
functions (as required by OpenGL).
A scene is defined and rendered in NuGraf by following these basic
steps:
The objects are defined through the use of modeling primitives such
as spheres, patches and polygons.
Materials are assigned to the objects
Lights are added to the scene
A camera is defined and positioned
An output driver is selected
The scene is rendered
The following tutorials will illustrate all of these steps, and
more.