Urho3D
Public Member Functions | Public Attributes | List of all members
Urho3D::BatchQueue Struct Reference

Queue that contains both instanced and non-instanced draw calls. More...

#include </home/runner/work/urho3d-doxygen.github.io/urho3d-doxygen.github.io/urho3d_repo/Source/Urho3D/Graphics/Batch.h>

Public Member Functions

void Clear (int maxSortedInstances)
 Clear for new frame by clearing all groups and batches.
 
void SortBackToFront ()
 Sort non-instanced draw calls back to front.
 
void SortFrontToBack ()
 Sort instanced and non-instanced draw calls front to back.
 
void SortFrontToBack2Pass (Vector< Batch * > &batches)
 Sort batches front to back while also maintaining state sorting.
 
void SetInstancingData (void *lockedData, i32 stride, i32 &freeIndex)
 Pre-set instance data of all groups. The vertex buffer must be big enough to hold all data.
 
void Draw (View *view, Camera *camera, bool markToStencil, bool usingLightOptimization, bool allowDepthWrite) const
 Draw.
 
i32 GetNumInstances () const
 Return the combined amount of instances.
 
bool IsEmpty () const
 Return whether the batch group is empty.
 

Public Attributes

HashMap< BatchGroupKey, BatchGroupbatchGroups_
 Instanced draw calls.
 
HashMap< hash32, hash32 > shaderRemapping_
 Shader remapping table for 2-pass state and distance sort.
 
HashMap< hash16, hash16 > materialRemapping_
 Material remapping table for 2-pass state and distance sort.
 
HashMap< hash16, hash16 > geometryRemapping_
 Geometry remapping table for 2-pass state and distance sort.
 
Vector< Batchbatches_
 Unsorted non-instanced draw calls.
 
Vector< Batch * > sortedBatches_
 Sorted non-instanced draw calls.
 
Vector< BatchGroup * > sortedBatchGroups_
 Sorted instanced draw calls.
 
i32 maxSortedInstances_
 Maximum sorted instances.
 
bool hasExtraDefines_
 Whether the pass command contains extra shader defines.
 
String vsExtraDefines_
 Vertex shader extra defines.
 
String psExtraDefines_
 Pixel shader extra defines.
 
StringHash vsExtraDefinesHash_
 Hash for vertex shader extra defines.
 
StringHash psExtraDefinesHash_
 Hash for pixel shader extra defines.
 

Detailed Description

Queue that contains both instanced and non-instanced draw calls.


The documentation for this struct was generated from the following files: