Om  1.0.0
A universal framework for multimedia simulation
Classes | Public Member Functions | List of all members
om::graphics::shapes::RenderQueue Class Reference

A class that contains all of the data needed to perform a rendering pass for a graphics scene. More...

#include <omGraphicsRenderQueue.h>

Public Member Functions

 RenderQueue ()
 Create a new empty render queue that is ready to be used for rendering. More...
 
void addMesh (const MeshChunk &mesh)
 Add a new mesh to the end of the render queue. More...
 
Size getMeshCount () const
 Return the number of meshes there are in this render queue. More...
 
const MeshChunkgetMesh (Index meshIndex) const
 Return a reference to the mesh chunk in this render queue at the given index. More...
 
void addDirectionalLight (const Light *newDirectionalLight)
 Add the specified directional light to this render queue. More...
 
void addPointLight (const Light *newPointLight, const Sphere3 &boundingSphere)
 Add the specified point light to this render queue. More...
 
void addSpotLight (const Light *newSpotLight, const BoundingCone &boundingCone)
 Add the specified spot light to this render queue. More...
 
Size getDirectionalLightCount () const
 Return a pointer to the directional light contained in this render queue at the specified index. More...
 
const LightgetDirectionalLight (Index index) const
 Return a pointer to the directional light contained in this render queue at the specified index. More...
 
const LightgetSortedDirectionalLight (Index index) const
 Return a pointer to the directional light contained in this render queue at the specified sorted index. More...
 
Size getPointLightCount () const
 Return a pointer to the point light contained in this render queue at the specified index. More...
 
const LightgetPointLight (Index index) const
 Return a pointer to the point light contained in this render queue at the specified index. More...
 
const LightgetSortedPointLight (Index index) const
 Return a pointer to the point light contained in this render queue at the specified sorted index. More...
 
Size getSpotLightCount () const
 Return a pointer to the spot light contained in this render queue at the specified index. More...
 
const LightgetSpotLight (Index index) const
 Return a pointer to the spot light contained in this render queue at the specified index. More...
 
const LightgetSortedSpotLight (Index index) const
 Return a pointer to the spot light contained in this render queue at the specified sorted index. More...
 
void clear ()
 Clear the render queue so that it is ready for another rendering pass. More...
 
void sortLights (const Sphere3 &detector, Size maxNumLights=Size(10))
 Sort the lights in this render queue in decreasing order based on the intensity for the given spherical detector. More...
 

Detailed Description

A class that contains all of the data needed to perform a rendering pass for a graphics scene.

Constructor & Destructor Documentation

om::graphics::shapes::RenderQueue::RenderQueue ( )

Create a new empty render queue that is ready to be used for rendering.

Member Function Documentation

void om::graphics::shapes::RenderQueue::addMesh ( const MeshChunk mesh)
inline

Add a new mesh to the end of the render queue.

Size om::graphics::shapes::RenderQueue::getMeshCount ( ) const
inline

Return the number of meshes there are in this render queue.

const MeshChunk& om::graphics::shapes::RenderQueue::getMesh ( Index  meshIndex) const
inline

Return a reference to the mesh chunk in this render queue at the given index.

void om::graphics::shapes::RenderQueue::addDirectionalLight ( const Light newDirectionalLight)
inline

Add the specified directional light to this render queue.

void om::graphics::shapes::RenderQueue::addPointLight ( const Light newPointLight,
const Sphere3 boundingSphere 
)
inline

Add the specified point light to this render queue.

void om::graphics::shapes::RenderQueue::addSpotLight ( const Light newSpotLight,
const BoundingCone boundingCone 
)
inline

Add the specified spot light to this render queue.

Size om::graphics::shapes::RenderQueue::getDirectionalLightCount ( ) const
inline

Return a pointer to the directional light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getDirectionalLight ( Index  index) const
inline

Return a pointer to the directional light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getSortedDirectionalLight ( Index  index) const
inline

Return a pointer to the directional light contained in this render queue at the specified sorted index.

Size om::graphics::shapes::RenderQueue::getPointLightCount ( ) const
inline

Return a pointer to the point light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getPointLight ( Index  index) const
inline

Return a pointer to the point light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getSortedPointLight ( Index  index) const
inline

Return a pointer to the point light contained in this render queue at the specified sorted index.

Size om::graphics::shapes::RenderQueue::getSpotLightCount ( ) const
inline

Return a pointer to the spot light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getSpotLight ( Index  index) const
inline

Return a pointer to the spot light contained in this render queue at the specified index.

const Light* om::graphics::shapes::RenderQueue::getSortedSpotLight ( Index  index) const
inline

Return a pointer to the spot light contained in this render queue at the specified sorted index.

void om::graphics::shapes::RenderQueue::clear ( )

Clear the render queue so that it is ready for another rendering pass.

void om::graphics::shapes::RenderQueue::sortLights ( const Sphere3 detector,
Size  maxNumLights = Size(10) 
)

Sort the lights in this render queue in decreasing order based on the intensity for the given spherical detector.

At most the given maximum number of lights are considered from the render queue. The lights are partially sorted by intensity at the detector in decreasing order.


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