GsplatProcessor and extra data streams for gaussian splats#8395
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
This PR adds GPU-based processing capabilities for Gaussian Splat data through a new GSplatProcessor class and extends the gsplat system to support custom per-splat texture streams. The changes enable real-time manipulation of splat properties (like colors) directly on the GPU, demonstrated by a new 3D painting example.
Changes:
- New
GSplatProcessorclass for GPU-based splat data processing with fragment shaders - Extended
GSplatFormatto support custom extra streams with resource-level or instance-level storage - Refactored shader function names from
readCenter/readColortogetCenter/getColorfor consistency - Added new stream storage constants and unified parameter handling for format-specific uniforms
Reviewed changes
Copilot reviewed 34 out of 37 changed files in this pull request and generated 6 comments.
Show a summary per file
| File | Description |
|---|---|
| src/framework/gsplat/gsplat-processor.js | New GPU processor class for reading/writing gsplat texture streams |
| src/scene/gsplat/gsplat-format.js | Added extra streams support, input/output declaration generation, and stream lookup |
| src/scene/gsplat/gsplat-resource-base.js | Added parameters map for non-texture uniforms |
| src/scene/gsplat/gsplat-sog-resource.js | Refactored to populate parameters map instead of direct material configuration |
| src/framework/components/gsplat/component.js | Enhanced resource getter to support both direct and asset-based resources |
| src/scene/constants.js | Added GSPLAT_STREAM_RESOURCE and GSPLAT_STREAM_INSTANCE constants |
| src/scene/shader-lib/*/chunks/gsplat/** | Renamed shader functions and added new processing/stream templates |
| examples/src/examples/gaussian-splatting/paint.** | New example demonstrating 3D painting on gaussian splats |
| src/index.js | Exported GSplatProcessor class |
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
slimbuck
approved these changes
Jan 21, 2026
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.
Summary
Adds GPU-based processing capabilities for Gaussian Splat data and support for custom per-splat texture streams.
Architecture
GSplatProcessor
New class for GPU-based processing of gsplat texture data using fragment shaders. Enables operations like modifying splat properties directly on the GPU.
GSplatResource(shared textures) orGSplatComponent(instance textures)Extra Streams
GSplatFormatnow supports adding custom texture streams beyond the standard splat data:Stream Storage Types
GSPLAT_STREAM_RESOURCE- Texture shared across all instances (default)GSPLAT_STREAM_INSTANCE- Texture created per component instancePublic API
Classes
GSplatProcessor- GPU processing of gsplat dataconstructor(device, source, destination, options)process()- Execute the processing shadersetParameter(name, value)- Set shader uniformsblendState- Configure output blendingdestroy()- Clean up resourcesGSplatFormat Methods
addExtraStreams(descriptors)- Add custom texture streamsConstants
GSPLAT_STREAM_RESOURCEGSPLAT_STREAM_INSTANCEGSplatComponent Methods
getInstanceTexture(name)- Get instance-level texture by stream nameShader API Changes
Renamed gsplat shader functions for consistency:
readCenter(source)getCenter(source)readColor(source)getColor(source)Example
New
gaussian-splatting/paintexample demonstrates 3D painting on gsplats using the processor API.Model supplied by Stéphane Agullo (thank you!) https://superspl.at/view?id=cdcec084