#include <scene.h>
Public Member Functions | |
virtual | ~IScene (void) |
Destruction. | |
virtual void | init (void)=0 |
Initialzes the scene object. | |
virtual void | shutdown (void)=0 |
Shutdowns the object and cleans up state. | |
virtual void | render (void)=0 |
Renders the scene with the currently set parameters. | |
virtual ICameraState * | getCameraState (void)=0 |
Returns the ICameraState responsible for this scene. | |
virtual ILightingState * | getLightingState (void)=0 |
Returns the ILightingState object responsible for this scene. | |
virtual ITextureState * | getTextureState (void)=0 |
Returns the ITextureState object responsible for this scene. | |
virtual IShader * | getShader (void)=0 |
Returns the IShader object responsible for this scene. | |
virtual void | setClearColor (const vec4_t &color)=0 |
Sets the viewport clear color. | |
virtual void | setCurrentModel (IModel *model)=0 |
Sets the current test model. | |
virtual IModel * | getCurrentModel (void)=0 |
Returns the current test model. | |
virtual void | setUseProgram (bool enable)=0 |
Sets the 'use program' flag. | |
virtual void | setShowOrigin (bool enable)=0 |
Sets the 'show origin' flag. | |
virtual void | setShowNormals (bool enable)=0 |
Sets the 'show normals' flag. | |
virtual void | setShowBoundingBox (bool enable)=0 |
Sets the 'show bounding box' flag. | |
virtual void | setShowTangents (bool enable)=0 |
Sets the 'show tangent space vectors' flag. | |
virtual void | setWireframe (bool enable)=0 |
Sets the 'draw as wireframe' flag. | |
virtual void | setBackFaceCulling (bool enable)=0 |
Sets the 'enable backface culling' flag. | |
Static Public Member Functions | |
static IScene * | create (void) |
Creates a IScene object. |
This is the central rendering parameter container. It stores state like the current test model, the camera parameters, texture iamges and several state flags. Last but not least it stores the IShader object that is responsible for rendering the test model.
IScene * IScene::create | ( | void | ) | [static] |
virtual void IScene::init | ( | void | ) | [pure virtual] |
Initialzes the scene object.
After this call the scene is ready to operate.
Implemented in CScene.
virtual void IScene::setClearColor | ( | const vec4_t & | color | ) | [pure virtual] |
virtual void IScene::setCurrentModel | ( | IModel * | model | ) | [pure 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.
model | The test model. |
Implemented in CScene.
virtual IModel* IScene::getCurrentModel | ( | void | ) | [pure virtual] |
virtual void IScene::setUseProgram | ( | bool | enable | ) | [pure 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.
Implemented in CScene.
virtual void IScene::setShowOrigin | ( | bool | enable | ) | [pure 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.
Implemented in CScene.
virtual void IScene::setShowNormals | ( | bool | enable | ) | [pure virtual] |
Sets the 'show normals' flag.
If this is set, the vertex normals of the current model will be drawn. The default is false.
Implemented in CScene.
virtual void IScene::setShowBoundingBox | ( | bool | enable | ) | [pure virtual] |
Sets the 'show bounding box' flag.
If this is set, the current model's bounding box will be drawn. The default is false.
Implemented in CScene.
virtual void IScene::setShowTangents | ( | bool | enable | ) | [pure 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.
Implemented in CScene.
virtual void IScene::setWireframe | ( | bool | enable | ) | [pure 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.
Implemented in CScene.
virtual void IScene::setBackFaceCulling | ( | bool | enable | ) | [pure virtual] |
Sets the 'enable backface culling' flag.
This enables/diables OpenGL back face culling for the test model. The default is false.
Implemented in CScene.