Skip to content

Commit

Permalink
WebGLBackend: Fix depth formats. (#30422)
Browse files Browse the repository at this point in the history
  • Loading branch information
Mugen87 authored Jan 29, 2025
1 parent 0b79d6f commit 7d4b4ae
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/renderers/webgl-fallback/utils/WebGLTextureUtils.js
Original file line number Diff line number Diff line change
Expand Up @@ -261,7 +261,8 @@ class WebGLTextureUtils {

if ( glFormat === gl.DEPTH_COMPONENT ) {

if ( glType === gl.UNSIGNED_INT ) internalFormat = gl.DEPTH24_STENCIL8;
if ( glType === gl.UNSIGNED_SHORT ) internalFormat = gl.DEPTH_COMPONENT16;
if ( glType === gl.UNSIGNED_INT ) internalFormat = gl.DEPTH_COMPONENT24;
if ( glType === gl.FLOAT ) internalFormat = gl.DEPTH_COMPONENT32F;

}
Expand Down

0 comments on commit 7d4b4ae

Please sign in to comment.