Преглед изворни кода

Fix wasm memory view not sized correctly

Popov72 пре 5 година
родитељ
комит
ce824b6a8a
1 измењених фајлова са 1 додато и 1 уклоњено
  1. 1 1
      src/Misc/KTX2/wasmMemoryManager.ts

+ 1 - 1
src/Misc/KTX2/wasmMemoryManager.ts

@@ -32,7 +32,7 @@ export class WASMMemoryManager {
             this._memoryView = new Uint8Array(this._memory.buffer, offset, byteLength);
             this._memoryView = new Uint8Array(this._memory.buffer, offset, byteLength);
             this._memoryViewByteLength = byteLength;
             this._memoryViewByteLength = byteLength;
             this._memoryViewOffset = offset;
             this._memoryViewOffset = offset;
-        } else if (this._memoryViewByteLength < byteLength || this._memoryViewOffset !== offset) {
+        } else {
             console.log("recreate view", this._memoryViewByteLength, byteLength, this._memoryViewOffset, offset);
             console.log("recreate view", this._memoryViewByteLength, byteLength, this._memoryViewOffset, offset);
             this._memoryView = new Uint8Array(this._memory.buffer, offset, byteLength);
             this._memoryView = new Uint8Array(this._memory.buffer, offset, byteLength);
             this._memoryViewByteLength = byteLength;
             this._memoryViewByteLength = byteLength;