! * \brief Adds the TileMap to the rendering queue * * \param renderQueue Queue to be added * \param instanceData Data for the instance */
| 24 | * \param instanceData Data for the instance |
| 25 | */ |
| 26 | void TileMap::AddToRenderQueue(AbstractRenderQueue* renderQueue, const InstanceData& instanceData) const |
| 27 | { |
| 28 | const VertexStruct_XYZ_Color_UV* vertices = reinterpret_cast<const VertexStruct_XYZ_Color_UV*>(instanceData.data.data()); |
| 29 | |
| 30 | std::size_t matCount = 0; |
| 31 | std::size_t spriteCount = 0; |
| 32 | for (const Layer& layer : m_layers) |
| 33 | { |
| 34 | renderQueue->AddSprites(instanceData.renderOrder, GetMaterial(matCount++), &vertices[spriteCount], layer.tiles.size()); |
| 35 | |
| 36 | spriteCount += layer.tiles.size(); |
| 37 | } |
| 38 | } |
| 39 | |
| 40 | void TileMap::MakeBoundingVolume() const |
| 41 | { |
nothing calls this directly
no test coverage detected