ReadonlymeshReadonlynodeThe node format finish hands out (the batch builds f32 nodes and packs them, unless quantizeOnEmit).
ReadonlyparentsThe batch writes each node's parent (GpuHplocBatchOptions.parents).
ReadonlyquantizeThe emit pass writes the quantized nodes itself (HplocOptions.quantizeOnEmit): no f32 nodes, no quantize pass.
ReadonlytriangleThe triangle format the batch writes.
GPU bytes of the output trees (nodes, triangles, parents), which finish hands to the caller.
GPU bytes the batch holds until finish or destroy: its inputs, scratch and uniforms (not the outputs; 0 on a scratch pool, which counts them).
Frees the scratch, the inputs and the uniforms. Trees handed out by finish are not touched.
Records every mesh's build into encoder: copies of any GPU-buffer
inputs, then one compute pass. timestampWrites (optional) times the pass.
For a breakdown, stageTimestamps instead puts each step in a pass of
its own and times it with the writes it returns. The extra passes cost a
little time themselves, so use it to compare steps, not to time the build.
OptionaltimestampWrites: GPUComputePassTimestampWritesOptionalstageTimestamps: (Reads every mesh's stats back (one copy and one map), checks them, and
returns the trees. Call after submitting an encode. Frees the batch's
scratch; the trees stay until the caller destroys them.
One batch of mesh builds: inputs, scratch and outputs, recorded into one compute pass.