Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

vrj::GlDrawConeWandFunctor Class Reference

Draw a basic cone wand. More...

#include <GlDrawWandFunctors.h>

Inheritance diagram for vrj::GlDrawConeWandFunctor:

Inheritance graph
[legend]
Collaboration diagram for vrj::GlDrawConeWandFunctor:

Collaboration graph
[legend]
List of all members.

Public Methods

virtual void contextInit ()
 Called to initialize any context specific information. More...

virtual void draw ()
 Callback function for drawing. More...


Protected Attributes

GLUquadricObj * mQuadObj

Detailed Description

Draw a basic cone wand.

Definition at line 49 of file GlDrawWandFunctors.h.


Member Function Documentation

virtual void vrj::GlDrawConeWandFunctor::contextInit   [inline, virtual]
 

Called to initialize any context specific information.

Implements vrj::GlDrawObjectFunctor.

Definition at line 53 of file GlDrawWandFunctors.h.

00054    {;}

virtual void vrj::GlDrawConeWandFunctor::draw   [inline, virtual]
 

Callback function for drawing.

Called when the object should be drawn.

Precondition:
GL context is set and ready to go.

Implements vrj::GlDrawObjectFunctor.

Definition at line 60 of file GlDrawWandFunctors.h.

References mQuadObj.

00061    {
00062       const float base = 0.2f;
00063       const float height = 0.6f;
00064       const int slices = 6;
00065       const int stacks = 1;
00066    
00067       if (mQuadObj == NULL)
00068       {
00069          mQuadObj = gluNewQuadric();
00070       }
00071 
00072       glColor3f(0.0f, 1.0f, 0.0f);
00073       gluQuadricDrawStyle(mQuadObj, (GLenum) GLU_FILL);
00074       gluQuadricNormals(mQuadObj, (GLenum) GLU_SMOOTH);
00075       gluCylinder(mQuadObj, base, 0.0, height, slices, stacks);
00076    }


Member Data Documentation

GLUquadricObj* vrj::GlDrawConeWandFunctor::mQuadObj [protected]
 

Definition at line 79 of file GlDrawWandFunctors.h.

Referenced by draw.


The documentation for this class was generated from the following file:
Generated on Sun May 2 15:11:10 2004 for VR Juggler by doxygen1.2.14 written by Dimitri van Heesch, © 1997-2002