Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | Class Members

Switch Class Reference
[Scene Graph]

#include <lvt/Group.h>

Inheritance diagram for Switch:

Inheritance graph
List of all members.

Detailed Description

Groups objects and selects one of those objects for rendering.

A Switch is a Group that renders only one of its child objects. Add children to a switch as you would a group, and select the index of the child to render with Select().

Public Member Functions

int GetCurSelection () const
 Returns the index of the currently selected child.
void Select (int n)
 Selects which child to render.
 Switch ()
 Default constructor.

Protected Member Functions

virtual void RenderChildren ()
 Renders the currently selected child object.

Constructor & Destructor Documentation

Switch  )  [inline]

Default constructor.

Sets the initially selected child object to the first to be added to the switch.

Member Function Documentation

int GetCurSelection  )  const [inline]

Returns the index of the currently selected child.

virtual void RenderChildren  )  [protected, virtual]

Renders the currently selected child object.

Reimplemented from Group.

Reimplemented in AutoSwitch.

void Select int  n  )  [inline]

Selects which child to render.

Selects the nth child as the child to render. It is acceptable for n to be greater than the number of objects in the Switch. In this case, nothing will be drawn with a call to Render() until an nth child is added to the switch.

Generated on Thu Feb 17 09:45:48 2005 for liblvt by  doxygen 1.4.1