Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

NodeMaterial: Only call setupDepth() with active depth buffer. #29799

Merged
merged 4 commits into from
Nov 4, 2024

Conversation

Mugen87
Copy link
Collaborator

@Mugen87 Mugen87 commented Nov 4, 2024

Related issue: #29797.

Description

This makes sure setupDepth() only configures a depth node if the current framebuffer (custom or default) has a configured depth buffer.

Copy link

github-actions bot commented Nov 4, 2024

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 692.35
171.47
692.35
171.47
+0 B
+0 B
WebGPU 822.12
221.89
822.19
221.91
+69 B
+20 B
WebGPU Nodes 821.41
221.74
821.48
221.76
+69 B
+22 B

🌳 Bundle size after tree-shaking

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

Before After Diff
WebGL 464.89
112.3
464.89
112.3
+0 B
+0 B
WebGPU 542.7
146.82
542.77
146.84
+69 B
+24 B
WebGPU Nodes 498.64
136.56
498.71
136.59
+69 B
+26 B

@Mugen87 Mugen87 changed the title NodeMaterial: Use early out in setupDepth(). NodeMaterial: Only call setupDepth() with active depth buffer. Nov 4, 2024
@Mugen87 Mugen87 added this to the r171 milestone Nov 4, 2024
@sunag sunag merged commit c3f685f into mrdoob:dev Nov 4, 2024
12 checks passed
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