Conversation
📦 Bundle sizeFull ESM build, minified and gzipped.
🌳 Bundle size after tree-shakingMinimal build including a renderer, camera, empty scene, and dependencies.
|
Owner
Author
|
Maybe #32180 makes VSM shadows redundant too... |
Collaborator
|
VSM can blur the shadow map as a whole which a great quality advantage over PCF. Also in #32180, you see the noise structure especially with larger radii at the shadow edges because there is no denoise or temporal filtering in place. Depending on the scene and how closely you look at the shadows, that could be considered as a quality issue (and a reason for using VSM). |
Owner
Author
|
That's true yeah. Okay, lets keep VSM 👌 |
mrdoob
pushed a commit
that referenced
this pull request
Nov 7, 2025
Port optimizations from PR #32181 to the WebGPU renderer: - Extract mean variable for clarity - Add early return optimization for fully lit pixels - Improve variable naming (d, p_max) - Correct variance epsilon from 0 to 0.0000001 - Pre-compute constant (0.65 instead of 0.95 - 0.3) - Remove redundant outer clamp - Add clarifying comments These changes improve performance by reducing operations per pixel while maintaining identical visual output.
mrdoob
added a commit
that referenced
this pull request
Nov 7, 2025
Port optimizations from PR #32181 to the WebGPU renderer: - Extract mean variable for clarity - Add early return optimization for fully lit pixels - Improve variable naming (d, p_max) - Correct variance epsilon from 0 to 0.0000001 - Pre-compute constant (0.65 instead of 0.95 - 0.3) - Remove redundant outer clamp - Add clarifying comments These changes improve performance by reducing operations per pixel while maintaining identical visual output. Co-authored-by: Claude <noreply@anthropic.com>
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
Changes
mean,variance,d,p_max) for clarityclamp()- result is already guaranteed to be in [0,1]0.65instead of0.95 - 0.3)0.00000to0.0000001to actually prevent division by zeroBenefits