Browse Source

Merge pull request #7296 from sebavan/master

Fix WipeCache VAO
sebavan 5 năm trước cách đây
mục cha
commit
b6dd3c7d12
1 tập tin đã thay đổi với 3 bổ sung1 xóa
  1. 3 1
      src/Engines/thinEngine.ts

+ 3 - 1
src/Engines/thinEngine.ts

@@ -2623,6 +2623,9 @@ export class ThinEngine {
         this._viewportCached.z = 0;
         this._viewportCached.w = 0;
 
+        // Done before in case we clean the attributes
+        this._unbindVertexArrayObject();
+
         if (bruteForce) {
             this._currentProgram = null;
             this.resetTextureCache();
@@ -2651,7 +2654,6 @@ export class ThinEngine {
         this._resetVertexBufferBinding();
         this._cachedIndexBuffer = null;
         this._cachedEffectForVertexBuffers = null;
-        this._unbindVertexArrayObject();
         this.bindIndexBuffer(null);
     }