Преглед на файлове

WebGPURenderer: Clean up.

Mugen87 преди 4 години
родител
ревизия
3fd2561cc9
променени са 1 файла, в които са добавени 2 реда и са изтрити 1 реда
  1. 2 1
      examples/jsm/renderers/webgpu/WebGPURenderPipelines.js

+ 2 - 1
examples/jsm/renderers/webgpu/WebGPURenderPipelines.js

@@ -10,12 +10,12 @@ class WebGPURenderPipelines {
 		this.bindings = bindings;
 
 		this.pipelines = new WeakMap();
+		this.shaderAttributes = new WeakMap();
 		this.shaderModules = {
 			vertex: new WeakMap(),
 			fragment: new WeakMap()
 		};
 
-		this.shaderAttributes = new WeakMap();
 
 	}
 
@@ -166,6 +166,7 @@ class WebGPURenderPipelines {
 	dispose() {
 
 		this.pipelines = new WeakMap();
+		this.shaderAttributes = new WeakMap();
 		this.shaderModules = {
 			vertex: new WeakMap(),
 			fragment: new WeakMap()