Scene Class Reference

#include <Scene.h>

Inheritance diagram for Scene:

GRAObject CornellBox FractalMount SphereFlake List of all members.

Public Member Functions

 Scene (const SDS &proto)
virtual ~Scene ()
SceneGraphObject::OID appendModel (Parser &parser, const Matrix4 *m=NULL)
SceneGraphObject::OID appendObject (SceneGraphObject *primitive)
SceneGraphObject::OID appendLight (LightSource *light)
void build (void)
bool haveLight (void) const
Group * root (void)
virtual void __debug (void)

Protected Attributes

SceneGraphObject::OID _lastOID
Group _sceneGraph
bool _haveLight

Detailed Description

Definition at line 18 of file Scene.h.


Constructor & Destructor Documentation

Scene const SDS &  proto  )  [inline]
 

Parameters:
proto prototype of the main spatial data structure

Definition at line 28 of file Scene.h.

virtual ~Scene  )  [inline, virtual]
 

Definition at line 33 of file Scene.h.


Member Function Documentation

void __debug void   )  [virtual]
 

Used only for debugging.

Definition at line 63 of file Scene.cc.

References Scene::_sceneGraph.

SceneGraphObject::OID appendLight LightSource *  light  ) 
 

Appends a light source to the scene.

Parameters:
light appended light source

Definition at line 53 of file Scene.cc.

References Scene::_haveLight, Scene::_lastOID, and Scene::_sceneGraph.

Referenced by CornellBox::_build_lights(), SphereFlake::_create_lights(), and FractalMount::_create_lights().

SceneGraphObject::OID appendModel Parser &  parser,
const Matrix4 *  m = NULL
 

Appends model to the scene.

Parameters:
parser parser of the model
m transfoprmation matrix of the model

Definition at line 7 of file Scene.cc.

References Scene::_lastOID, and Scene::_sceneGraph.

SceneGraphObject::OID appendObject SceneGraphObject *  primitive  ) 
 

Appends single object to the scene.

Parameters:
primitive appended object

Definition at line 32 of file Scene.cc.

References Scene::_lastOID, and Scene::_sceneGraph.

Referenced by CornellBox::_build_sphere_flake(), CornellBox::_build_walls(), SphereFlake::_create_spheres(), FractalMount::_create_spheres(), CornellBox::addCrystalicSphere(), CornellBox::addMirrorSphere(), and SphereFlake::SphereFlake().

void build void   )  [inline]
 

Prepares the scene for manipulation. There is no guarantee that the scene is realy created until the build() method is called. After the build() call the scene is created. Nevertheless, you _can_ still append additional primitives and/or models.

Definition at line 65 of file Scene.h.

Referenced by FractalMount::FractalMount(), and SphereFlake::SphereFlake().

bool haveLight void   )  const [inline]
 

Returns:
true if the scene has light, false otherwise

Definition at line 70 of file Scene.h.

Group* root void   )  [inline]
 

Returns:
root of the scene graph

Definition at line 75 of file Scene.h.

Referenced by RayTracing::_cast_ray(), PhotonMapShader::_create_maps_per_shape(), PhotonMapShader::_create_scene_maps(), PhotonMapShader::_emit_caustic_photon(), PhotonMapShader::_emit_global_photon(), LocalReflection::_light_visible(), RTRender::_render(), GLRender::_render(), GLPhotonMapRender::_render(), GLIrradCacheRender::_render(), GLBVRender::_render(), GLEnergyRender::_render_energy(), PhotonMapShader::distributeEnergy(), RayTracing::illuminatePoint(), PhotonTracing::illuminatePoint(), Render::renderScene(), RadShader::setScene(), Radiosity::setScene(), PhotonMapping::setScene(), and LocalReflection::setScene().


Member Data Documentation

bool _haveLight [protected]
 

Definition at line 22 of file Scene.h.

Referenced by Scene::appendLight().

SceneGraphObject::OID _lastOID [protected]
 

Definition at line 20 of file Scene.h.

Referenced by CornellBox::_build_lights(), CornellBox::_build_sphere_flake(), CornellBox::_build_walls(), SphereFlake::_create_spheres(), FractalMount::_create_spheres(), CornellBox::addCrystalicSphere(), CornellBox::addMirrorSphere(), Scene::appendLight(), Scene::appendModel(), Scene::appendObject(), and SphereFlake::SphereFlake().

Group _sceneGraph [protected]
 

Definition at line 21 of file Scene.h.

Referenced by Scene::__debug(), Scene::appendLight(), Scene::appendModel(), and Scene::appendObject().


The documentation for this class was generated from the following files:
Generated on Tue Nov 21 15:11:43 2006 for gra by  doxygen 1.4.6