VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
8 - 2D Rendering

An overlay is a 2D scene that is drawn on top of a 3D scene.

The 2D scene can contain any number of the 2D primitives, which include: DtLineSegment, DtQuad, DtFilledPolygon, and DtOutlinedPolygon. The class that implements the overlay concept is the DtOverlayRenderer. The DtOverlayRenderer does the actual drawing of the graphical primitives.

To draw an overlay you must add a DtOverlayDrawable to the scene. The DtOverlayDrawable is responsible for telling overlays (instances of DtOverlayRenderer) to render themselves at the appropriate time.

The DtOverlayDrawable is told which DtOverlayRenderer it should draw. During the render phase, the DtOverlayDrawable tells the DtOverlayRenderer to render itself and the graphics primitives are then rendered.

The exampleLogo example shows how to create an overlay.

The window object API makes use of overlays to draw on screen :

[Home]


Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)