SSGINode: Fix Sampling Asymmetry#31867
Merged
Merged
Conversation
Make the SSGI pass work closer to the way it was intended to... Also enables panning in the demo scene (to better examine the GI).
Contributor
There was a problem hiding this comment.
Pull Request Overview
This PR fixes a sampling asymmetry issue in the SSGI (Screen Space Global Illumination) Node by correcting the rotation angle calculation and enables panning in the demo scene for better examination of the global illumination effects.
- Fixed sampling asymmetry by changing PI to PI2 in rotation angle calculation
- Enabled panning controls in the SSGI demo scene
Reviewed Changes
Copilot reviewed 2 out of 2 changed files in this pull request and generated 1 comment.
| File | Description |
|---|---|
| examples/jsm/tsl/display/SSGINode.js | Fixed rotation angle calculation using PI2 instead of PI to resolve sampling asymmetry |
| examples/webgpu_postprocessing_ssgi.html | Enabled panning controls in demo for better GI examination |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
Mugen87
approved these changes
Sep 9, 2025
Contributor
Author
|
Oops wait I forgot the thumbnail 💀 |
Collaborator
|
That's okay, we do not include it in the E2E tests yet. There are some CI issues with examples that use renderings with noise or random values. |
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.
Description
Live Demo: https://rawcdn.githack.com/zalo/three.js/fix-ssgi-rotations/examples/webgpu_postprocessing_ssgi.html
Make the SSGI pass work closer to the way it was intended to... Also enables panning in the demo scene (to better examine the GI). @Mugen87 @cdrintherrieno
Related issue: #31839
Recording.2025-09-09.123545.mp4
We should switch to a better target model (like the LittleTokyo model), but I won't porkbarrel this fix any more than this 😅