feat(gsplat): cast directional shadows from the hybrid renderer#8933
Merged
Conversation
The GPU-sort (hybrid) gsplat renderer can now cast directional shadows, which previously only the CPU-sort quad renderer could. A new GSplatShadowRenderer runs a projection-free compute cull (coarse octree-node vs light-frustum reject) producing an unsorted visible-index buffer, then a quad-style per-vertex-projected indirect draw via the standard shadow-caster pipeline (no sort, no projection cache). It supports any number of non-cascaded directional lights, each with its own cull + draw, fanning out at the renderer level only (one GSplatWorld per manager regardless of light count). A separate shadow-only manager no longer allocates the unused forward sorter/projector. Adds a Lights slider (0-6) to the gaussian-splatting/shadows example.
Build size reportThis PR changes the size of the minified bundles.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Lets the GPU-sort (hybrid) gsplat renderer cast directional shadows — previously only the CPU-sort quad renderer could, so scenes using the hybrid renderer got no gsplat shadows.
Changes:
GSplatShadowRenderer: a projection-free compute cull (coarse octree-node vs light-frustum reject) producing an unsorted visible-index buffer, then a quad-style per-vertex-projected indirect draw via the standard shadow-caster pipeline (no sort, no projection cache).GSplatWorldper manager regardless of light count.gsplat-interval-data.js) reused by the forward interval compaction and the shadow cull.Examples:
gaussian-splatting/shadows: added a "Lights" slider (0–6) demonstrating multiple directional gsplat shadows (lights evenly spaced at the full count, rotating together).Performance: