Instanced drawing is a drawing technique that relies on a single draw call being made to the graphics API and letting the GPU draw several instances of the same base mesh.
Each mesh instance can be controlled by per instance properties provided under the form of per instance attributes.
Kuesa::MeshInstantiator simplifies that process by expecting users provide an array of QMatrix4x4 transformations. The number of transformations dictates the number of instances to draw and each instance will be transformed by one of the transformations.
There is no strict limitations on how many instances can be drawn as it is GPU dependent. For simple meshes, this can easily be thousands of instances.
Note: For the instances to be visible, you should ensure that either frustum culling is disabled or that the initial instances (the mesh with no transformation applies) fit within the view frustum. Furthermore care needs to be taken to not share the material you intend to use with the instanced meshes with the material used for non instanced meshes.
The number of instances being drawn. It will be at least 1 even if no transformation matrices were provided.
The name of the entity to be retrieved from the Kuesa::EntityCollection and instantiated.