Browse Source

Update WebGLUtils for WebGL 2.0 UNSIGNED_INT_24_8

Takahiro 7 years ago
parent
commit
f02117fe85
1 changed files with 1 additions and 1 deletions
  1. 1 1
      src/renderers/webgl/WebGLUtils.js

+ 1 - 1
src/renderers/webgl/WebGLUtils.js

@@ -142,7 +142,7 @@ function WebGLUtils( gl, extensions ) {
 
 
 			extension = extensions.get( 'WEBGL_depth_texture' );
 			extension = extensions.get( 'WEBGL_depth_texture' );
 
 
-			if ( extension !== null ) return extension.UNSIGNED_INT_24_8_WEBGL;
+			if ( extension !== null ) return isWebGL2 ? extension.UNSIGNED_INT_24_8 : extension.UNSIGNED_INT_24_8_WEBGL;
 
 
 		}
 		}