Skip to main content

Module indirect_dispatch

Module indirect_dispatch 

Source
Expand description

Indirect dispatch support for GPU compute kernels.

Indirect dispatch allows the GPU to determine workgroup counts from a buffer rather than from CPU-side values. This is essential for data-dependent workloads where the number of items is computed by a previous GPU pass (e.g., compaction, prefix-sum driven dispatch).

Structs§

IndirectBuffer
A buffer that holds indirect dispatch arguments.
IndirectDispatchArgs
Arguments for an indirect compute dispatch, matching the layout expected by wgpu::RenderPass::dispatch_workgroups_indirect.

Enums§

DispatchStrategy
Strategy for computing indirect dispatch arguments from an element count and a workgroup size.

Functions§

compute_dispatch
Compute dispatch arguments from an element count and strategy.
validate_dispatch_limits
Validates that dispatch arguments do not exceed device limits.