-
-
Notifications
You must be signed in to change notification settings - Fork 35.2k
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
Different default background colors of WebGLRenderer and WebGPURenderer #28751
Comments
Actually, that is not quite true. renderer = new THREE.WebGLRenderer(); // clear color is black; clear alpha is 1
renderer = new THREE.WebGLRenderer( { alpha: false } ); // clear color is black; clear alpha is 1
renderer = new THREE.WebGLRenderer( { alpha: true } ); // clear color is black; clear alpha is 0 And regardless of the backend, renderer = new WebGPURenderer(); // clear color is black; clear alpha is 0
renderer = new WebGPURenderer( { alpha: false } ); // clear color is black; clear alpha is 1
renderer = new WebGPURenderer( { alpha: true } ); // clear color is black; clear alpha is 0 |
Thanks for the clarification. It's my bad I didn't check the alpha, I was only considering the visual effect. So, in the vec3 interpretation of background color both renderers work the same, but sill in the vec4 interpretation they act differently. |
This issue has two aspects. The value of clear alpha and whether the rendering context is created as transparent or opaque. In In If we want to strictly align IMO, the default clear alpha value should be Ideally, I would remove |
Description
The default background color of
WebGLRenderer
is black.The default background color of
WebGPURenderer
is white.It will improve the consistency if both renderers have the same default background colors.
Reproduction steps
Code
(See the live examples for code)
Live example
Screenshots
WebGL black background (the canvas has red border):
WebGPU white background (the canvas has red border):
Version
r165
Device
Desktop
Browser
Chrome, Firefox
OS
Windows
The text was updated successfully, but these errors were encountered: