Fill aSortedIndex[0..count) with identity ordering and register a
single collapsed prefix update range. Ranges accumulate across
commits while a mesh is not drawn and the WebGPU backends replay
them verbatim (no flush-time merge), so every write collapses the
pending set to one [0, max-end) range.
Also re-homes the geometry on SLOT 0, which is what makes the split
ownership of the swap safe. The slot lives on the geometry (so it
survives the pool's release/re-acquire with the buffers it describes)
while the selector uniform lives on the material, and the pool re-pairs
the two freely: a geometry a sorted tenant left on slot 1, handed to a
node whose fresh material defaults to slot 0, would draw the PREVIOUS
tenant's permutation over a different element count — and an
order-independent tenant is never tracked by the coordinator, so
nothing would push the slot to its uniform. A full identity write is
precisely the fresh-start signal, so normalising here means a default
uniform is always correct and untracked nodes need no sync at all.
The Points and Lines append writers deliberately differ: their adapters
call writeSortedIndexIdentityRange to preserve the live prefix
permutation. GSplat appends call this full writer instead, trading that
prefix prior for one coherent storage-order fallback over the grown node.
Fill
aSortedIndex[0..count)with identity ordering and register a single collapsed prefix update range. Ranges accumulate across commits while a mesh is not drawn and the WebGPU backends replay them verbatim (no flush-time merge), so every write collapses the pending set to one[0, max-end)range.Also re-homes the geometry on SLOT 0, which is what makes the split ownership of the swap safe. The slot lives on the geometry (so it survives the pool's release/re-acquire with the buffers it describes) while the selector uniform lives on the material, and the pool re-pairs the two freely: a geometry a sorted tenant left on slot 1, handed to a node whose fresh material defaults to slot 0, would draw the PREVIOUS tenant's permutation over a different element count — and an order-independent tenant is never tracked by the coordinator, so nothing would push the slot to its uniform. A full identity write is precisely the fresh-start signal, so normalising here means a default uniform is always correct and untracked nodes need no sync at all.
The Points and Lines append writers deliberately differ: their adapters call writeSortedIndexIdentityRange to preserve the live prefix permutation. GSplat appends call this full writer instead, trading that prefix prior for one coherent storage-order fallback over the grown node.