Browse Source

WebGPUTextures: Clean up. (#25876)

Michael Herzog 2 years ago
parent
commit
883df2ec97
1 changed files with 4 additions and 7 deletions
  1. 4 7
      examples/jsm/renderers/webgpu/WebGPUTextures.js

+ 4 - 7
examples/jsm/renderers/webgpu/WebGPUTextures.js

@@ -605,9 +605,6 @@ class WebGPUTextures {
 		if ( format === GPUTextureFormat.ASTC12x10Unorm || format === GPUTextureFormat.ASTC12x10UnormSRGB ) return { byteLength: 16, width: 12, height: 10 };
 		if ( format === GPUTextureFormat.ASTC12x12Unorm || format === GPUTextureFormat.ASTC12x12UnormSRGB ) return { byteLength: 16, width: 12, height: 12 };
 
-
-
-
 	}
 
 	_getBytesPerTexel( format ) {
@@ -730,10 +727,6 @@ class WebGPUTextures {
 					formatGPU = ( colorSpace === SRGBColorSpace ) ? GPUTextureFormat.ASTC12x12UnormSRGB : GPUTextureFormat.ASTC12x12Unorm;
 					break;
 
-				case DepthFormat:
-					formatGPU = GPUTextureFormat.Depth32Float;
-					break;
-
 				default:
 					console.error( 'WebGPURenderer: Unsupported texture format.', format );
 
@@ -812,6 +805,10 @@ class WebGPUTextures {
 
 					break;
 
+				case DepthFormat:
+					formatGPU = GPUTextureFormat.Depth32Float;
+					break;
+
 				default:
 					console.error( 'WebGPURenderer: Unsupported texture format.', format );