Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | File List | Namespace Members | Class Members | File Members | Related Pages

Ogre::RenderQueueInvocation Class Reference

Class representing the invocation of queue groups in a RenderQueue. More...

#include <OgreRenderQueueInvocation.h>

List of all members.

Public Member Functions

 RenderQueueInvocation (uint8 renderQueueGroupID, const String &invocationName=StringUtil::BLANK)
 Constructor.

virtual ~RenderQueueInvocation ()
virtual uint8 getRenderQueueGroupID (void) const
 Get the render queue group id.

virtual const StringgetInvocationName (void) const
 Get the invocation name (may be blank if not set by creator).

virtual void setSolidsOrganisation (QueuedRenderableCollection::OrganisationMode org)
 Set the organisation mode being used for solids in this queue group invocation.

virtual QueuedRenderableCollection::OrganisationMode getSolidsOrganisation (void) const
 Get the organisation mode being used for solids in this queue group invocation.

virtual void setSuppressShadows (bool suppress)
 Sets whether shadows are suppressed when invoking this queue.

virtual bool getSuppressShadows (void) const
 Gets whether shadows are suppressed when invoking this queue.

virtual void setSuppressRenderStateChanges (bool suppress)
 Sets whether render state changes are suppressed when invoking this queue.

virtual bool getSuppressRenderStateChanges (void) const
 Gets whether shadows are suppressed when invoking this queue.

virtual void invoke (RenderQueueGroup *group, SceneManager *targetSceneManager)
 Invoke this class on a concrete queue group.


Static Public Attributes

String RENDER_QUEUE_INVOCATION_SHADOWS
 Invocation identifier for shadows.


Protected Attributes

uint8 mRenderQueueGroupID
 Target queue group.

String mInvocationName
 Invocation identifier - used in listeners.

QueuedRenderableCollection::OrganisationMode mSolidsOrganisation
 Solids ordering mode.

bool mSuppressShadows
 Suppress shadows processing in this invocation?

bool mSuppressRenderStateChanges
 Suppress OGRE's render state management?


Detailed Description

Class representing the invocation of queue groups in a RenderQueue.

Remarks:
The default behaviour for OGRE's render queue is to render each queue group in turn, dealing with shadows automatically, and rendering solids in grouped passes, followed by transparent objects in descending order. This class, together with RenderQueueInvocationSequence and the ability to associate one with a Viewport, allows you to change that behaviour and render queue groups in arbitrary sequence, repeatedly, and to skip shadows, change the ordering of solids, or even prevent OGRE controlling the render state during a particular invocation for special effects.
Note that whilst you can change the ordering of rendering solids, you can't change the ordering on transparent objects, since to do this would cause them to render incorrectly.
As well as using this class directly and using the options it provides you with, you can also provide subclasses of it to a RenderQueueInvocationSequence instance if you want to gain ultimate control.
Note:
Invocations will be skipped if there are scene-level options preventing them being rendered - for example special-case render queues and render queue listeners that dictate this.

Definition at line 57 of file OgreRenderQueueInvocation.h.


Constructor & Destructor Documentation

Ogre::RenderQueueInvocation::RenderQueueInvocation uint8  renderQueueGroupID,
const String invocationName = StringUtil::BLANK
 

Constructor.

Parameters:
renderQueueGroupID ID of the queue this will target
invocationName Optional name to uniquely identify this invocation from others in a RenderQueueListener

virtual Ogre::RenderQueueInvocation::~RenderQueueInvocation  )  [virtual]
 


Member Function Documentation

virtual const String& Ogre::RenderQueueInvocation::getInvocationName void   )  const [virtual]
 

Get the invocation name (may be blank if not set by creator).

Definition at line 84 of file OgreRenderQueueInvocation.h.

References Ogre::String.

virtual uint8 Ogre::RenderQueueInvocation::getRenderQueueGroupID void   )  const [virtual]
 

Get the render queue group id.

Definition at line 81 of file OgreRenderQueueInvocation.h.

References Ogre::uint8.

virtual QueuedRenderableCollection::OrganisationMode Ogre::RenderQueueInvocation::getSolidsOrganisation void   )  const [virtual]
 

Get the organisation mode being used for solids in this queue group invocation.

Definition at line 97 of file OgreRenderQueueInvocation.h.

virtual bool Ogre::RenderQueueInvocation::getSuppressRenderStateChanges void   )  const [virtual]
 

Gets whether shadows are suppressed when invoking this queue.

Definition at line 136 of file OgreRenderQueueInvocation.h.

virtual bool Ogre::RenderQueueInvocation::getSuppressShadows void   )  const [virtual]
 

Gets whether shadows are suppressed when invoking this queue.

Definition at line 109 of file OgreRenderQueueInvocation.h.

virtual void Ogre::RenderQueueInvocation::invoke RenderQueueGroup group,
SceneManager targetSceneManager
[virtual]
 

Invoke this class on a concrete queue group.

Remarks:
Implementation will send the queue group to the target scene manager after doing what it needs to do.

virtual void Ogre::RenderQueueInvocation::setSolidsOrganisation QueuedRenderableCollection::OrganisationMode  org  )  [virtual]
 

Set the organisation mode being used for solids in this queue group invocation.

Definition at line 89 of file OgreRenderQueueInvocation.h.

virtual void Ogre::RenderQueueInvocation::setSuppressRenderStateChanges bool  suppress  )  [virtual]
 

Sets whether render state changes are suppressed when invoking this queue.

Remarks:
When doing special effects you may want to set up render state yourself and have it apply for the entire rendering of a queue. In that case, you should call this method with a parameter of 'true', and use a RenderQueueListener to set the render state directly on RenderSystem yourself before the invocation.
Suppressing render state changes is only intended for advanced use, don't use it if you're unsure of the effect. The only RenderSystem calls made are to set the world matrix for each object (note - view an projection matrices are NOT SET - they are under your control) and to render the object; it is up to the caller to do everything else, including enabling any vertex / fragment programs and updating their parameter state, and binding parameters to the RenderSystem. We advise you use a RenderQueueListener in order to get a notification when this invocation is going to happen (use an invocation name to identify it if you like), at which point you can set the state you need to apply before the objects are rendered.

Definition at line 131 of file OgreRenderQueueInvocation.h.

virtual void Ogre::RenderQueueInvocation::setSuppressShadows bool  suppress  )  [virtual]
 

Sets whether shadows are suppressed when invoking this queue.

Remarks:
When doing effects you often will want to suppress shadow processing if shadows will already have been done by a previous render.

Definition at line 104 of file OgreRenderQueueInvocation.h.


Member Data Documentation

String Ogre::RenderQueueInvocation::mInvocationName [protected]
 

Invocation identifier - used in listeners.

Definition at line 63 of file OgreRenderQueueInvocation.h.

uint8 Ogre::RenderQueueInvocation::mRenderQueueGroupID [protected]
 

Target queue group.

Definition at line 61 of file OgreRenderQueueInvocation.h.

QueuedRenderableCollection::OrganisationMode Ogre::RenderQueueInvocation::mSolidsOrganisation [protected]
 

Solids ordering mode.

Definition at line 65 of file OgreRenderQueueInvocation.h.

bool Ogre::RenderQueueInvocation::mSuppressRenderStateChanges [protected]
 

Suppress OGRE's render state management?

Definition at line 69 of file OgreRenderQueueInvocation.h.

bool Ogre::RenderQueueInvocation::mSuppressShadows [protected]
 

Suppress shadows processing in this invocation?

Definition at line 67 of file OgreRenderQueueInvocation.h.

String Ogre::RenderQueueInvocation::RENDER_QUEUE_INVOCATION_SHADOWS [static]
 

Invocation identifier for shadows.

Definition at line 146 of file OgreRenderQueueInvocation.h.


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

Copyright © 2000-2005 by The OGRE Team
Creative Commons License
This work is licensed under a Creative Commons Attribution-ShareAlike 2.5 License.
Last modified Sun Mar 12 14:42:05 2006