#include <OgreRenderQueueSortingGrouping.h>
Public Types | |
typedef std::vector< RenderablePass > | TransparentRenderablePassList |
Vector of RenderablePass objects, this is built on the assumption that vectors only ever increase in size, so even if we do clear() the memory stays allocated, ie fast. | |
typedef std::vector< Renderable * > | RenderableList |
typedef std::map< Pass *, RenderableList *, SolidQueueItemLess > | SolidRenderablePassMap |
Map of pass to renderable lists, used for solid objects since ordering within objects not important. | |
Public Methods | |
RenderPriorityGroup (RenderQueueGroup *parent, bool splitPassesByLightingType, bool splitNoShadowPasses) | |
~RenderPriorityGroup () | |
const SolidRenderablePassMap & | _getSolidPasses (void) const |
Get the collection of solid passes currently queued. | |
const SolidRenderablePassMap & | _getSolidPassesDiffuseSpecular (void) const |
Get the collection of solid passes currently queued (per-light). | |
const SolidRenderablePassMap & | _getSolidPassesDecal (void) const |
Get the collection of solid passes currently queued (decal textures). | |
const SolidRenderablePassMap & | _getSolidPassesNoShadow (void) const |
Get the collection of solid passes for which shadow receipt is disabled. | |
const TransparentRenderablePassList & | _getTransparentPasses (void) const |
Get the collection of transparent passes currently queued. | |
void | addRenderable (Renderable *pRend) |
Add a renderable to this group. | |
void | sort (const Camera *cam) |
Sorts the objects which have been added to the queue; transparent objects by their depth in relation to the passed in Camera. | |
void | clear (void) |
Clears this group of renderables. | |
void | setSplitPassesByLightingType (bool split) |
Sets whether or not the queue will split passes by their lighting type, ie ambient, per-light and decal. | |
void | setSplitNoShadowPasses (bool split) |
Sets whether or not passes which have shadow receive disabled should be separated. | |
Protected Methods | |
void | destroySolidPassMap (SolidRenderablePassMap &passmap) |
Totally empties and destroys a solid pass map. | |
void | removeSolidPassEntry (Pass *p) |
remove a pass entry from all solid pass maps | |
void | clearSolidPassMap (SolidRenderablePassMap &passmap) |
Clear a solid pass map at the end of a frame. | |
void | addSolidRenderable (Technique *pTech, Renderable *rend, bool toNoShadowMap) |
Internal method for adding a solid renderable. | |
void | addSolidRenderableSplitByLightType (Technique *pTech, Renderable *rend) |
Internal method for adding a solid renderable. | |
void | addTransparentRenderable (Technique *pTech, Renderable *rend) |
Internal method for adding a transparent renderable. | |
Protected Attributes | |
RenderQueueGroup * | mParent |
Parent queue group. | |
bool | mSplitPassesByLightingType |
bool | mSplitNoShadowPasses |
SolidRenderablePassMap | mSolidPasses |
Solid pass list, used when no shadows, modulative shadows, or ambient passes for additive. | |
SolidRenderablePassMap | mSolidPassesDiffuseSpecular |
Solid per-light pass list, used with additive shadows. | |
SolidRenderablePassMap | mSolidPassesDecal |
Solid decal (texture) pass list, used with additive shadows. | |
SolidRenderablePassMap | mSolidPassesNoShadow |
Solid pass list, used when shadows are enabled but shadow receive is turned off for these passes. | |
TransparentRenderablePassList | mTransparentPasses |
Transparent list. |
This class optimises the grouped renderables by sorting them by material to reduce render state changes, and outsorts transparent objects.
Definition at line 50 of file OgreRenderQueueSortingGrouping.h.
|
Definition at line 120 of file OgreRenderQueueSortingGrouping.h. Referenced by addSolidRenderable(), and addSolidRenderableSplitByLightType(). |
|
Map of pass to renderable lists, used for solid objects since ordering within objects not important.
Definition at line 123 of file OgreRenderQueueSortingGrouping.h. Referenced by _getSolidPasses(), _getSolidPassesDecal(), _getSolidPassesDiffuseSpecular(), _getSolidPassesNoShadow(), addSolidRenderable(), and addSolidRenderableSplitByLightType(). |
|
Vector of RenderablePass objects, this is built on the assumption that vectors only ever increase in size, so even if we do clear() the memory stays allocated, ie fast.
Definition at line 119 of file OgreRenderQueueSortingGrouping.h. Referenced by _getTransparentPasses(). |
|
Definition at line 157 of file OgreRenderQueueSortingGrouping.h. References mSplitNoShadowPasses, and mSplitPassesByLightingType. |
|
Definition at line 162 of file OgreRenderQueueSortingGrouping.h. References destroySolidPassMap(), mSolidPasses, mSolidPassesDecal, mSolidPassesDiffuseSpecular, mSolidPassesNoShadow, and mTransparentPasses. |
|
Get the collection of solid passes currently queued.
Definition at line 173 of file OgreRenderQueueSortingGrouping.h. References mSolidPasses, and SolidRenderablePassMap. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderBasicQueueGroupObjects(), Ogre::SceneManager::renderModulativeStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderModulativeTextureShadowedQueueGroupObjects(), Ogre::SceneManager::renderTextureShadowCasterQueueGroupObjects(), and Ogre::SceneManager::renderTextureShadowReceiverQueueGroupObjects(). |
|
Get the collection of solid passes currently queued (decal textures).
Definition at line 179 of file OgreRenderQueueSortingGrouping.h. References mSolidPassesDecal, and SolidRenderablePassMap. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(). |
|
Get the collection of solid passes currently queued (per-light).
Definition at line 176 of file OgreRenderQueueSortingGrouping.h. References mSolidPassesDiffuseSpecular, and SolidRenderablePassMap. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(). |
|
Get the collection of solid passes for which shadow receipt is disabled.
Definition at line 182 of file OgreRenderQueueSortingGrouping.h. References mSolidPassesNoShadow, and SolidRenderablePassMap. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderModulativeStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderModulativeTextureShadowedQueueGroupObjects(), and Ogre::SceneManager::renderTextureShadowCasterQueueGroupObjects(). |
|
Get the collection of transparent passes currently queued.
Definition at line 185 of file OgreRenderQueueSortingGrouping.h. References mTransparentPasses, and TransparentRenderablePassList. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderBasicQueueGroupObjects(), Ogre::SceneManager::renderModulativeStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderModulativeTextureShadowedQueueGroupObjects(), and Ogre::SceneManager::renderTextureShadowCasterQueueGroupObjects(). |
|
Add a renderable to this group.
Definition at line 95 of file OgreRenderQueueSortingGrouping.cpp. References addSolidRenderable(), addSolidRenderableSplitByLightType(), addTransparentRenderable(), Ogre::Renderable::getMaterial(), Ogre::Technique::getParent(), Ogre::Material::getReceiveShadows(), Ogre::Renderable::getTechnique(), Ogre::Technique::isDepthCheckEnabled(), Ogre::Technique::isDepthWriteEnabled(), Ogre::Technique::isTransparent(), and mSplitNoShadowPasses. Referenced by Ogre::RenderQueueGroup::addRenderable(). |
|
Internal method for adding a solid renderable.
Definition at line 140 of file OgreRenderQueueSortingGrouping.cpp. References Ogre::Technique::getPassIterator(), mSolidPasses, mSolidPassesNoShadow, RenderableList, and SolidRenderablePassMap. Referenced by addRenderable(). |
|
Internal method for adding a solid renderable.
Definition at line 178 of file OgreRenderQueueSortingGrouping.cpp. References Ogre::Technique::getIlluminationPassIterator(), Ogre::IS_AMBIENT, Ogre::IS_DECAL, Ogre::IS_PER_LIGHT, mSolidPasses, mSolidPassesDecal, mSolidPassesDiffuseSpecular, Ogre::IlluminationPass::pass, RenderableList, SolidRenderablePassMap, and Ogre::IlluminationPass::stage. Referenced by addRenderable(). |
|
Internal method for adding a transparent renderable.
Definition at line 219 of file OgreRenderQueueSortingGrouping.cpp. References Ogre::Technique::getPassIterator(), and mTransparentPasses. Referenced by addRenderable(). |
|
Clears this group of renderables.
Definition at line 239 of file OgreRenderQueueSortingGrouping.cpp. References clearSolidPassMap(), mSolidPasses, mSolidPassesDecal, mSolidPassesDiffuseSpecular, mSolidPassesNoShadow, mTransparentPasses, and removeSolidPassEntry(). |
|
Clear a solid pass map at the end of a frame.
Definition at line 84 of file OgreRenderQueueSortingGrouping.cpp. Referenced by clear(). |
|
Totally empties and destroys a solid pass map.
Definition at line 31 of file OgreRenderQueueSortingGrouping.cpp. Referenced by ~RenderPriorityGroup(). |
|
remove a pass entry from all solid pass maps
Definition at line 44 of file OgreRenderQueueSortingGrouping.cpp. References mSolidPasses, mSolidPassesDecal, mSolidPassesDiffuseSpecular, and mSolidPassesNoShadow. Referenced by clear(). |
|
Sets whether or not passes which have shadow receive disabled should be separated.
Definition at line 211 of file OgreRenderQueueSortingGrouping.h. References mSplitNoShadowPasses. |
|
Sets whether or not the queue will split passes by their lighting type, ie ambient, per-light and decal.
Definition at line 203 of file OgreRenderQueueSortingGrouping.h. References mSplitPassesByLightingType. |
|
Sorts the objects which have been added to the queue; transparent objects by their depth in relation to the passed in Camera.
Definition at line 230 of file OgreRenderQueueSortingGrouping.cpp. References Ogre::RenderPriorityGroup::TransparentQueueItemLess::camera, and mTransparentPasses. Referenced by Ogre::SceneManager::renderAdditiveStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderBasicQueueGroupObjects(), Ogre::SceneManager::renderModulativeStencilShadowedQueueGroupObjects(), Ogre::SceneManager::renderModulativeTextureShadowedQueueGroupObjects(), and Ogre::SceneManager::renderTextureShadowCasterQueueGroupObjects(). |
|
Parent queue group.
Definition at line 126 of file OgreRenderQueueSortingGrouping.h. |
|
Solid pass list, used when no shadows, modulative shadows, or ambient passes for additive.
Definition at line 130 of file OgreRenderQueueSortingGrouping.h. Referenced by _getSolidPasses(), addSolidRenderable(), addSolidRenderableSplitByLightType(), clear(), removeSolidPassEntry(), and ~RenderPriorityGroup(). |
|
Solid decal (texture) pass list, used with additive shadows.
Definition at line 134 of file OgreRenderQueueSortingGrouping.h. Referenced by _getSolidPassesDecal(), addSolidRenderableSplitByLightType(), clear(), removeSolidPassEntry(), and ~RenderPriorityGroup(). |
|
Solid per-light pass list, used with additive shadows.
Definition at line 132 of file OgreRenderQueueSortingGrouping.h. Referenced by _getSolidPassesDiffuseSpecular(), addSolidRenderableSplitByLightType(), clear(), removeSolidPassEntry(), and ~RenderPriorityGroup(). |
|
Solid pass list, used when shadows are enabled but shadow receive is turned off for these passes.
Definition at line 136 of file OgreRenderQueueSortingGrouping.h. Referenced by _getSolidPassesNoShadow(), addSolidRenderable(), clear(), removeSolidPassEntry(), and ~RenderPriorityGroup(). |
|
Definition at line 128 of file OgreRenderQueueSortingGrouping.h. Referenced by addRenderable(), RenderPriorityGroup(), and setSplitNoShadowPasses(). |
|
Definition at line 127 of file OgreRenderQueueSortingGrouping.h. Referenced by RenderPriorityGroup(), and setSplitPassesByLightingType(). |
|
Transparent list.
Definition at line 139 of file OgreRenderQueueSortingGrouping.h. Referenced by _getTransparentPasses(), addTransparentRenderable(), clear(), sort(), and ~RenderPriorityGroup(). |
Copyright © 2002-2003 by The OGRE Team
Last modified Sun Nov 28 19:51:28 2004