Add 2D Gaussian Splatting (2DGS) Rendering Support #8416
Merged
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.
Add 2D Gaussian Splatting (2DGS) Rendering Support
This PR adds support for rendering 2D Gaussian Splats using a new
GSPLAT_2DGSshader define, similar to the existingGSPLAT_AAdefine.Summary
GSPLAT_2DGSconditional rendering path for 2D Gaussian SplattingSplatCorner.offsetfromvec2tovec3to support both 3DGS (clip-space XY) and 2DGS (model-space XYZ)initCorner2DGSfunctionTechnical Details
2DGS Rendering Approach:
Quaternion Rotation:
Uses direct quaternion-vector rotation formula (faster than matrix conversion):
Public API Changes
New Shader Define:
GSPLAT_2DGS- When enabled, uses the 2DGS oriented quad rendering path instead of the 3DGS covariance-based pathStruct Change:
SplatCorner.offset: Changed fromvec2/vec2ftovec3/vec3fFiles Changed
src/scene/shader-lib/glsl/chunks/gsplat/vert/gsplatStructs.jssrc/scene/shader-lib/glsl/chunks/gsplat/vert/gsplatCorner.jssrc/scene/shader-lib/glsl/chunks/gsplat/vert/gsplat.jssrc/scene/shader-lib/wgsl/chunks/gsplat/vert/gsplatStructs.jssrc/scene/shader-lib/wgsl/chunks/gsplat/vert/gsplatCorner.jssrc/scene/shader-lib/wgsl/chunks/gsplat/vert/gsplat.jsTest Plan
GSPLAT_2DGSdefine and verify 2DGS splats render correctly