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

WebGLBackground: Respect autoClear in XR. #26428

Merged
merged 1 commit into from
Jul 31, 2023

Conversation

CodyJasonBennett
Copy link
Contributor

@CodyJasonBennett CodyJasonBennett commented Jul 14, 2023

Fixed #25955

Description

Unsets forceClear when handling the WebXR environment blendmode. Noticed this while testing #26160 which breaks the backgrounds-postprocessing example.

I didn't move this into the renderer.autoClear || forceClear guard as a best effort attempt to get a correct render between successive frames when manually clearing via renderer.clear() => renderer.render() etc.

@github-actions
Copy link

📦 Bundle size

Full ESM build, minified and gzipped.

Filesize dev Filesize PR Diff
643.9 kB (159.7 kB) 643.9 kB (159.7 kB) -39 B

🌳 Bundle size after tree-shaking

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

Filesize dev Filesize PR Diff
437 kB (105.8 kB) 437 kB (105.8 kB) -39 B

@Mugen87 Mugen87 added this to the r155 milestone Jul 16, 2023
@Mugen87
Copy link
Collaborator

Mugen87 commented Jul 19, 2023

@mrxz @marwie Can you confirm that this PR fixes your use cases?

@mrxz
Copy link
Contributor

mrxz commented Jul 26, 2023

This does indeed fix my use-case (which is purely VR, environment blend mode opaque).

@mrdoob mrdoob modified the milestones: r155, r156 Jul 27, 2023
@Mugen87 Mugen87 changed the title WebGLBackground: respect autoClear in AR WebGLBackground: Respect autoClear in AR. Jul 31, 2023
@Mugen87 Mugen87 changed the title WebGLBackground: Respect autoClear in AR. WebGLBackground: Respect autoClear in XR. Jul 31, 2023
@Mugen87 Mugen87 merged commit cefdf9b into mrdoob:dev Jul 31, 2023
@CodyJasonBennett CodyJasonBennett deleted the background-ar branch July 31, 2023 09:25
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.

WebGLBackground: renderer.autoClear has no effect when an XR session is active
4 participants