Pool + wasm options; see WorkerSpzGltfSplatDecoderOptions.
ReadonlyconcurrencyWorker pool size — size the engine's decode concurrency to match.
Decode one .glb gaussian-splat tile on a pool worker.
The .glb tile bytes; transferred into the worker (decoded once,
not reused after the call).
The decoded GltfSplatCloud (parallel Float32Arrays in the tile's
glb-local frame). Same shape as SpzGltfSplatDecoder.decode.
Optional PackingGltfSplatDecoder capability: decode AND rebase/pack into the
shared ENU splat-texture layout IN THE WORKER, so the O(N-splat) pack never runs
on the main thread. Output-identical to the engine's main-thread decode() +
packEnu() fallback.
The .glb tile bytes; transferred into the worker.
Column-major 4×4 matrix mapping ECEF → the scene's shared local ENU frame (meters). Shared across tiles; cloned to the worker, not transferred.
Column-major 4×4 tile→ECEF transform from the 3D-Tiles traversal (the accumulated tile world matrix). Cloned to the worker.
The tile's geometric error (LOD value); baked per-splat into the spare texel slot so the renderer can apply LOD-adaptive splat dilation.
A PackedSplatTile (from @bitruvius/tiles3d): the GPU-ready packed
texture data plus tightly-packed ENU xyz positions for the global depth sort.
Terminate all pool workers and release them. Safe to call more than once.
Off-main-thread SpzGltfSplatDecoder: fans
.glbtile decodes out to aWorkerPoolof module workers so the heavy entropy decode (and the wasm→JS array copies) never block the render thread. Drop-in for SpzGltfSplatDecoder (samedecode(glb)contract from@bitruvius/geo-core'sGltfSplatDecoder), so the streaming engine + layer don't know the difference.Remarks
Also implements the optional
PackingGltfSplatDecodercapability via decodePackedEnu, letting@bitruvius/tiles3dmove the O(N-splat) ENU rebase/pack into the worker too. Call dispose to tear the pool down.Example