Skip to content

Renderer: Disable autoClear in the output pass.#30454

Merged
sunag merged 1 commit into
mrdoob:devfrom
Mugen87:dev3
Feb 4, 2025
Merged

Renderer: Disable autoClear in the output pass.#30454
sunag merged 1 commit into
mrdoob:devfrom
Mugen87:dev3

Conversation

@Mugen87
Copy link
Copy Markdown
Collaborator

@Mugen87 Mugen87 commented Feb 4, 2025

Related issue: #30450

Description

As stated in the existing comment in Renderer.clear(), a clear operation should only affect the internal intermediate render target and not the canvas framebuffer. However, when autoClear is enabled, the output pass will clear the canvas which breaks multi-view rendering: https://jsfiddle.net/tea4dchg/

The PR fixes the issue by disabling auto clear and also moves the output pass related logic into an own method.

@Mugen87 Mugen87 added this to the r174 milestone Feb 4, 2025
@github-actions
Copy link
Copy Markdown

github-actions Bot commented Feb 4, 2025

📦 Bundle size

Full ESM build, minified and gzipped.

Before After Diff
WebGL 336.12
78.22
336.12
78.22
+0 B
+0 B
WebGPU 517.05
143.52
516.99
143.53
-67 B
+12 B
WebGPU Nodes 516.52
143.42
516.45
143.43
-67 B
+11 B

🌳 Bundle size after tree-shaking

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

Before After Diff
WebGL 465.17
112.09
465.17
112.09
+0 B
+0 B
WebGPU 589.05
159.72
588.99
159.73
-67 B
+11 B
WebGPU Nodes 544.42
149.28
544.35
149.28
-67 B
+10 B

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