![]() |
Lysa
0.0
Lysa 3D Engine
|
Compute pipeline that generates DrawCommand entries entirely on the GPU.
Public Member Functions | |
| GenerateDrawCommands (pipeline_id pipelineId, const vireo::Buffer &activeInstancesBuffer, const DeviceMemoryArray &instancesArray, const DeviceMemoryArray &meshInstancesArray, const vireo::Buffer &drawCommandsBuffer, const vireo::Buffer &drawCommandsCountBuffer) | |
| void | dispatch (vireo::CommandList &commandList, uint32 activeInstancesCount) |
| virtual | ~GenerateDrawCommands () = default |
| GenerateDrawCommands (GenerateDrawCommands &) = delete | |
| GenerateDrawCommands & | operator= (GenerateDrawCommands &) = delete |
Static Public Member Functions | |
| static void | cleanup () |
| GenerateDrawCommands | ( | pipeline_id | pipelineId, |
| const vireo::Buffer & | activeInstancesBuffer, | ||
| const DeviceMemoryArray & | instancesArray, | ||
| const DeviceMemoryArray & | meshInstancesArray, | ||
| const vireo::Buffer & | drawCommandsBuffer, | ||
| const vireo::Buffer & | drawCommandsCountBuffer | ||
| ) |
Constructs a GpuDrawSetup pipeline.
| pipelineId | Identifier of the parent material pipeline (debug names). |
| activeInstancesBuffer | GPU buffer of active instanceIndex values |
| instancesBuffer | Global instances buffer |
| meshInstancesBuffer | Scene meshInstances buffer |
| drawCommandsBuffer | Output DrawCommand buffer. |
| drawCommandsCountBuffer | Atomic counter buffer, reset each frame. |
|
virtualdefault |
|
delete |
|
static |
Releases shared (static) GPU resources. Call once at shutdown.
| void dispatch | ( | vireo::CommandList & | commandList, |
| uint32 | activeInstancesCount | ||
| ) |
Clears the counter then dispatches the compute shader.
| commandList | Command list to record into. |
| activeInstancesCount | Number of entries in activeInstancesBuffer. |
|
delete |