Scene Class Reference

Scenes contain all the geometry and components needed to render something. More...

#include <ecscene.h>

Inheritance diagram for Scene:

EclipseObject

List of all members.

Public Member Functions

 Scene ()
 Creates a new scene.
YRSceneGetScenePtr ()
 Provide a pointer to our internal scene object.
void AddIntegrator (SurfaceIntegrator *a_pIntegrator)
 Add a surface integrator.
void AddLight (Light *a_pLight)
 Adds a light into our scene.
void SetAntialias (int a_nSamples, int a_nPasses, int a_nIncSamples, double a_fThreshold)
 Assigns antialias parameters.
void Render (Film *a_pFilm, YRCamera *a_pCamera=NULL)
 Triggers the main render procedure Triggers all render operations over the registered meshes, using whatever lights, materials, and surface integrators are available.
virtual PYOBJECT PyAsString ()
 Python text representation method This function must be implemented by all children.

Static Public Member Functions

static bool PyTypeCheck (PYOBJECT a_pObject)
 Python type check Verifies that the provided python object encapsulates our class.

Protected Member Functions

 ~Scene ()
 Only our Delete function can destroy a scene.
virtual void DeleteObject ()
 Child message hook for reference-count based destruction.


Detailed Description

Scenes contain all the geometry and components needed to render something.

Defines a scene wrapper around YR scene.

They are also the creators of several geometry components such as meshes, vertices, etc.

Instead of writing a complete wrapper for the scene_t object, simply obtain a pointer to it, and call whatever function is needed.

The class owns our actual YR scene.

Author:
Dan Torres 2008/12/12

Definition at line 54 of file ecscene.h.


Member Function Documentation

void Scene::AddIntegrator ( SurfaceIntegrator a_pIntegrator  ) 

Add a surface integrator.

Parameters:
a concrete SurfaceIntergrator object

void Scene::AddLight ( Light a_pLight  ) 

Adds a light into our scene.

Parameters:
a_pLight A concrete Light object

virtual void Scene::DeleteObject (  )  [protected, virtual]

Child message hook for reference-count based destruction.

The child class is responsible for deleting any instance to which this this function is called.

Reimplemented from EclipseObject.

YRScene* Scene::GetScenePtr (  )  [inline]

Provide a pointer to our internal scene object.

Returns:
a_pScene A pointer to a scene_t object

Definition at line 71 of file ecscene.h.

Referenced by Mesh::GetYRTrimesh().

virtual PYOBJECT Scene::PyAsString (  )  [virtual]

Python text representation method This function must be implemented by all children.

Returns:
A python string object with a description of ourselves

Reimplemented from EclipseObject.

static bool Scene::PyTypeCheck ( PYOBJECT  a_pObject  )  [static]

Python type check Verifies that the provided python object encapsulates our class.

Returns:
True if the provided object type is the same as ours

Reimplemented from EclipseObject.

void Scene::Render ( Film a_pFilm,
YRCamera a_pCamera = NULL 
)

Triggers the main render procedure Triggers all render operations over the registered meshes, using whatever lights, materials, and surface integrators are available.

If a camera is not provided, a conventional perspective camera is used instead.

Parameters:
a_pFilm The film used to render this scene 8
a_pCamera An optional camera for rendering.

void Scene::SetAntialias ( int  a_nSamples,
int  a_nPasses,
int  a_nIncSamples,
double  a_fThreshold 
)

Assigns antialias parameters.

Parameters:
a_nSamples Number of samples
a_nPasses Number of render passes
a_nIncSamples Number of samples for incremental passes
a_fThreshold Antialias threshold


The documentation for this class was generated from the following file:

Generated on Tue Jan 20 17:58:00 2009 for EclipseRay by  doxygen 1.5.7.1