Browse Source

Fix issue with texture optim when gl was used externally

David Catuhe 7 năm trước cách đây
mục cha
commit
2b84c3c86d
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      src/Engine/babylon.engine.ts

+ 1 - 1
src/Engine/babylon.engine.ts

@@ -1347,7 +1347,7 @@
         public resetTextureCache() {
             for (var key in this._boundTexturesCache) {
                 let boundTexture = this._boundTexturesCache[key];
-                if (boundTexture) {
+                if (!this.disableTextureBindingOptimization && boundTexture) {
                     this._removeDesignatedSlot(boundTexture);
                 }
                 this._boundTexturesCache[key] = null;