Skip to content

Conversation

@mrdoob
Copy link
Owner

@mrdoob mrdoob commented Oct 21, 2025

Related issue: #32067, #32073

Description

Adds a computeMultiBounceAO() function that accounts for light bouncing multiple times in occluded areas, based on surface albedo. This prevents overly dark AO on bright/colored surfaces while maintaining proper darkness in truly occluded areas.

  • Uses the polynomial approximation from "Practical Real-Time Strategies for Accurate Indirect Occlusion"
  • Applied only to diffuse indirect lighting

https://raw.githack.com/mrdoob/three.js/multibounce-ao-simple/examples/index.html

@github-actions
Copy link

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 350.11
84.81
350.45
84.94
+341 B
+128 B
WebGPU 604.06
169.4
604.06
169.4
+0 B
+0 B
WebGPU Nodes 602.66
169.16
602.66
169.16
+0 B
+0 B

🌳 Bundle size after tree-shaking

Minimal build including a renderer, camera, empty scene, and dependencies.

Before After Diff
WebGL 481.77
119.56
482.11
119.69
+341 B
+128 B
WebGPU 673.47
184.84
673.47
184.84
+0 B
+0 B
WebGPU Nodes 615.47
168.09
615.47
168.09
+0 B
+0 B

@mrdoob mrdoob added this to the r181 milestone Oct 21, 2025
@mrdoob mrdoob modified the milestones: r181, r182 Oct 31, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants