Browse Source

WebGPU.js: Added GPUShaderStage polyfill.

Mr.doob 3 years ago
parent
commit
f2c5357b09
1 changed files with 6 additions and 0 deletions
  1. 6 0
      examples/jsm/capabilities/WebGPU.js

+ 6 - 0
examples/jsm/capabilities/WebGPU.js

@@ -1,3 +1,9 @@
+if ( window.GPUShaderStage === undefined ) {
+
+	window.GPUShaderStage = { VERTEX: 1, FRAGMENT: 2, COMPUTE: 4 };
+
+}
+
 class WebGPU {
 class WebGPU {
 
 
 	static isAvailable() {
 	static isAvailable() {