cluster_allocate.wgsl
Bindings
@group(0)
@binding(3)
var<storage, read_write>
scratchpad_offsets_and_counts:
ClusterOffsetsAndCounts
Functions
@compute
Runs custom parallel code on the GPU, not limited to graphics
@workgroup_size(256, 1, 1)
Defines the size of a thread group. One to three numbers: width (x), height (y), and depth (z). Missing values default to 1
@compute
Runs custom parallel code on the GPU, not limited to graphics
@workgroup_size(256, 1, 1)
Defines the size of a thread group. One to three numbers: width (x), height (y), and depth (z). Missing values default to 1
The global allocation pass that propagates the offsets from each chunk of 256 clusters to later chunks sequentially.
Returns the total number of objects in the given cluster.
The local allocation pass that, for each chunk of 256 clusters, calculates the offset for each cluster in the chunk.