You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
It's possible render into specific mipmap levels when we set the target.texture.mipmaps array. This works great for color-only render targets, however if we give this target a depth buffer (either through depthBuffer: true or an explicit depthTexture), rendering will fail with a crash when rendering
The crash is caused by three.js assuming .__webglFramebuffer is a single framebuffer, however, when .mipmaps is set it becomes an array:
I'm implementing fast bloom and reflections that blur with distance – for this I render the scene to mipmap 0, then set the other mipmap levels by progressively gaussian blurring
Unfortunately I need a depth buffer both for rendering the scene into mip 0 and for screen space ray marching
Using mipmaps is much preferable to a set of textures because sample a given blur radius using the miplevel is just
Description
It's possible render into specific mipmap levels when we set the target.texture.mipmaps array. This works great for color-only render targets, however if we give this target a depth buffer (either through depthBuffer: true or an explicit depthTexture), rendering will fail with a crash when rendering
The crash is caused by three.js assuming .__webglFramebuffer is a single framebuffer, however, when .mipmaps is set it becomes an array:
This causes a crash on this line
three.js/src/renderers/webgl/WebGLTextures.js
Line 1663 in fc4ef55
And
three.js/src/renderers/webgl/WebGLTextures.js
Line 1532 in fc4ef55
Maybe other places too
See related
Reproduction steps
Create a WebGLRenderTarget with depthBuffer: true or depthTexture set
Try to render to this render target (any mipmap level)
Crash during initialization of the target
Code
Crash :[
Live example
latest
Screenshots
Version
174
Device
Desktop
Browser
Chrome
OS
MacOS
The text was updated successfully, but these errors were encountered: