Selaa lähdekoodia

Fix gpu.dispose()

David Catuhe 7 vuotta sitten
vanhempi
commit
04ddd5a61f
1 muutettua tiedostoa jossa 6 lisäystä ja 1 poistoa
  1. 6 1
      src/Particles/babylon.gpuParticleSystem.ts

+ 6 - 1
src/Particles/babylon.gpuParticleSystem.ts

@@ -1194,7 +1194,12 @@
             if (this._limitVelocityGradientsTexture) {
                 this._limitVelocityGradientsTexture.dispose();
                 (<any>this._limitVelocityGradientsTexture) = null;
-            }         
+            }                   
+
+            if (this._dragGradientsTexture) {
+                this._dragGradientsTexture.dispose();
+                (<any>this._dragGradientsTexture) = null;
+            }               
          
             if (this._randomTexture) {
                 this._randomTexture.dispose();