浏览代码

wgpu: fix mode which is u64 not unwrapping big int

Laytan Laats 6 月之前
父节点
当前提交
1223b3e260
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      vendor/wgpu/wgpu.js

+ 1 - 0
vendor/wgpu/wgpu.js

@@ -1365,6 +1365,7 @@ class WebGPUInterface {
 			 */
 			 */
 			wgpuBufferMapAsync: (bufferIdx, mode, offset, size, callbackInfoPtr) => {
 			wgpuBufferMapAsync: (bufferIdx, mode, offset, size, callbackInfoPtr) => {
 				const buffer = this.buffers.get(bufferIdx);
 				const buffer = this.buffers.get(bufferIdx);
+				mode   = this.unwrapBigInt(mode);
 				offset = this.unwrapBigInt(offset);
 				offset = this.unwrapBigInt(offset);
 				size   = this.unwrapBigInt(size);
 				size   = this.unwrapBigInt(size);