Closed Mugen87 closed 2 months ago
When rendering into a sRGB marked render target, the renderer does not have to perform sRGB output conversion. E.g. the SRGB8_ALPHA8
format from WebGL 2 automatically stores the written fragments as sRGB and decodes them back to linear-srgb as part of the filtering.
It seems WebGPURenderer
tries to force output color space conversion which should not be done in this case.
Description
WebGPURenderer
should be able to automatically convert equirectangular texture to the cube map format. I've tried to implement auto-conversion forenvMap
inBasicEnvironmentNode
but then encountered an issue.CubeRenderTarget.fromEquirectangularTexture()
(which internally usesCubeCamera.update()
) only works if the input islinear-srgb
. If it issrgb
which is more or less always true for non HDR textures, the rendering fails with the following WebGPU warnings:The renderer logs this for the
baseArrayLayer
1-5 which means for the cube sides 1-5. The first one seems to render as expected.Reproduction steps
Code
Live example
https://jsfiddle.net/hLcnrsfb/
Screenshots
No response
Version
r167dev
Device
Desktop
Browser
Chrome
OS
MacOS