CScene Class Reference

Implementation of IScene. More...

Inheritance diagram for CScene:

IScene

List of all members.

Public Member Functions

void init (void)
 Initialzes the scene object.
void shutdown (void)
 Shutdowns the object and cleans up state.
void render (void)
 Renders the scene with the currently set parameters.
ICameraStategetCameraState (void)
 Returns the ICameraState responsible for this scene.
ILightingStategetLightingState (void)
 Returns the ILightingState object responsible for this scene.
ITextureStategetTextureState (void)
 Returns the ITextureState object responsible for this scene.
IShadergetShader (void)
 Returns the IShader object responsible for this scene.
void setCurrentModel (IModel *model)
 Sets the current test model.
IModelgetCurrentModel (void)
 Returns the current test model.
void setClearColor (const vec4_t &color)
 Sets the viewport clear color.
void setUseProgram (bool enable)
 Sets the 'use program' flag.
void setWireframe (bool enable)
 Sets the 'draw as wireframe' flag.
void setBackFaceCulling (bool enable)
 Sets the 'enable backface culling' flag.
void setShowOrigin (bool enable)
 Sets the 'show origin' flag.
void setShowNormals (bool enable)
 Sets the 'show normals' flag.
void setShowBoundingBox (bool enable)
 Sets the 'show bounding box' flag.
void setShowTangents (bool enable)
 Sets the 'show tangent space vectors' flag.


Detailed Description

Implementation of IScene.

This class doensn't add new functionality. It is only used to hide the class definition from the interface definition.


Member Function Documentation

void CScene::init ( void   )  [virtual]

Initialzes the scene object.

After this call the scene is ready to operate.

Precondition:
Assumes a valid OpenGL 2.0 context active.

Implements IScene.

void CScene::setCurrentModel ( IModel model  )  [inline, virtual]

Sets the current test model.

The default test model is NULL. The test model is NOT stored here, it only keeps a pointer to the model. You have to delete the model manually.

Parameters:
model The test model.

Implements IScene.

IModel* CScene::getCurrentModel ( void   )  [inline, virtual]

Returns the current test model.

Implements IScene.

void CScene::setClearColor ( const vec4_t color  )  [inline, virtual]

Sets the viewport clear color.

Parameters:
color Clear color.

Implements IScene.

void CScene::setUseProgram ( bool  enable  )  [inline, virtual]

Sets the 'use program' flag.

If this is set, the test model is rendered using the userdefines shader program. If this is cleared, the test model is rendered using the OpenGL fixed function pipeline. The default it true.

Implements IScene.

void CScene::setWireframe ( bool  enable  )  [inline, virtual]

Sets the 'draw as wireframe' flag.

If this is set, GL_POLYGON_MODE will be set to GL_LINES for the test model. Otherwise if is GL_FILL. The default is false.

Implements IScene.

void CScene::setBackFaceCulling ( bool  enable  )  [inline, virtual]

Sets the 'enable backface culling' flag.

This enables/diables OpenGL back face culling for the test model. The default is false.

Implements IScene.

void CScene::setShowOrigin ( bool  enable  )  [inline, virtual]

Sets the 'show origin' flag.

If enabled, the world origin is shown by three lines indicationg the primary coordinate system axes. The default is false.

Implements IScene.

void CScene::setShowNormals ( bool  enable  )  [inline, virtual]

Sets the 'show normals' flag.

If this is set, the vertex normals of the current model will be drawn. The default is false.

Implements IScene.

void CScene::setShowBoundingBox ( bool  enable  )  [inline, virtual]

Sets the 'show bounding box' flag.

If this is set, the current model's bounding box will be drawn. The default is false.

Implements IScene.

void CScene::setShowTangents ( bool  enable  )  [inline, virtual]

Sets the 'show tangent space vectors' flag.

If this is set, the tanget space vectors of every vertex of the current model will be drawn. The default is false.

Implements IScene.


The documentation for this class was generated from the following file:
Generated on Sun Mar 2 17:12:32 2008 for Shader Maker by  doxygen 1.5.4