OGRE 14.3
Object-Oriented Graphics Rendering Engine
|
Lowest level collection of renderables. More...
#include <OgreRenderQueueSortingGrouping.h>
Public Types | |
enum | OrganisationMode { OM_PASS_GROUP = 1 , OM_SORT_DESCENDING = 2 , OM_SORT_ASCENDING = 6 } |
Organisation modes required for this collection. More... | |
Public Member Functions | |
QueuedRenderableCollection () | |
void | acceptVisitor (QueuedRenderableVisitor *visitor, OrganisationMode om) const |
Accept a visitor over the collection contents. | |
void | addOrganisationMode (OrganisationMode om) |
Add a required sorting / grouping mode to this collection when next used. | |
void | addRenderable (Pass *pass, Renderable *rend) |
Add a renderable to the collection using a given pass. | |
void | clear (void) |
Empty the collection. | |
void | merge (const QueuedRenderableCollection &rhs) |
Merge renderable collection. | |
void | removePassGroup (Pass *p) |
Remove the group entry (if any) for a given Pass. | |
void | resetOrganisationModes (void) |
Reset the organisation modes required for this collection. | |
void | sort (const Camera *cam) |
Perform any sorting that is required on this collection. | |
Lowest level collection of renderables.
To iterate over items in this collection, you must call the accept method and supply a QueuedRenderableVisitor. The order of the iteration, and whether that iteration is over a RenderablePass list or a 2-level grouped list which causes a visit call at the Pass level, and a call for each Renderable underneath.
Organisation modes required for this collection.
This affects the internal placement of the items added to this collection; if only one type of sorting / grouping is to be required, then renderables can be stored only once, whilst if multiple types are going to be needed then internally there will be multiple organisations. Changing the organisation needs to be done when the collection is empty.
Ogre::QueuedRenderableCollection::QueuedRenderableCollection | ( | ) |
Remove the group entry (if any) for a given Pass.
To be used when a pass is destroyed, such that any grouping level for it becomes useless.
Reset the organisation modes required for this collection.
You can only do this when the collection is empty.
|
inline |
Add a required sorting / grouping mode to this collection when next used.
You can only do this when the collection is empty.
void Ogre::QueuedRenderableCollection::addRenderable | ( | Pass * | pass, |
Renderable * | rend | ||
) |
Add a renderable to the collection using a given pass.
Perform any sorting that is required on this collection.
cam | The camera |
void Ogre::QueuedRenderableCollection::acceptVisitor | ( | QueuedRenderableVisitor * | visitor, |
OrganisationMode | om | ||
) | const |
Accept a visitor over the collection contents.
visitor | Visitor class which should be called back |
om | The organisation mode which you want to iterate over. Note that this must have been included in an addOrganisationMode call before any renderables were added. |
void Ogre::QueuedRenderableCollection::merge | ( | const QueuedRenderableCollection & | rhs | ) |
Merge renderable collection.