diff --git a/package-lock.json b/package-lock.json index 846a2271f685..83e5633167c4 100644 --- a/package-lock.json +++ b/package-lock.json @@ -23,7 +23,7 @@ "@types/serve-index": "^1.9.3", "@typescript-eslint/eslint-plugin": "^6.9.1", "@typescript-eslint/parser": "^6.9.1", - "@webgpu/types": "^0.1.40", + "@webgpu/types": "^0.1.42", "ansi-colors": "4.1.3", "babel-plugin-add-header-comment": "^1.0.3", "babel-plugin-const-enum": "^1.2.0", @@ -1523,9 +1523,9 @@ "dev": true }, "node_modules/@webgpu/types": { - "version": "0.1.40", - "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.40.tgz", - "integrity": "sha512-/BBkHLS6/eQjyWhY2H7Dx5DHcVrS2ICj9owvSRdgtQT6KcafLZA86tPze0xAOsd4FbsYKCUBUQyNi87q7gV7kw==", + "version": "0.1.42", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.42.tgz", + "integrity": "sha512-uvJtt4OD1Vjdebrrz3kNLgpOicYbikwnM8WPG6YD2lkCOHDtPdEtCINJFIFtbOCtPfA8SreR/vKyUNbAt92IwQ==", "dev": true }, "node_modules/abbrev": { @@ -10045,9 +10045,9 @@ "dev": true }, "@webgpu/types": { - "version": "0.1.40", - "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.40.tgz", - "integrity": "sha512-/BBkHLS6/eQjyWhY2H7Dx5DHcVrS2ICj9owvSRdgtQT6KcafLZA86tPze0xAOsd4FbsYKCUBUQyNi87q7gV7kw==", + "version": "0.1.42", + "resolved": "https://registry.npmjs.org/@webgpu/types/-/types-0.1.42.tgz", + "integrity": "sha512-uvJtt4OD1Vjdebrrz3kNLgpOicYbikwnM8WPG6YD2lkCOHDtPdEtCINJFIFtbOCtPfA8SreR/vKyUNbAt92IwQ==", "dev": true }, "abbrev": { diff --git a/package.json b/package.json index ac075b1e2160..a94ca4bb2c02 100644 --- a/package.json +++ b/package.json @@ -49,7 +49,7 @@ "@types/serve-index": "^1.9.3", "@typescript-eslint/eslint-plugin": "^6.9.1", "@typescript-eslint/parser": "^6.9.1", - "@webgpu/types": "^0.1.40", + "@webgpu/types": "^0.1.42", "ansi-colors": "4.1.3", "babel-plugin-add-header-comment": "^1.0.3", "babel-plugin-const-enum": "^1.2.0", diff --git a/src/webgpu/api/validation/resource_usages/texture/in_render_misc.spec.ts b/src/webgpu/api/validation/resource_usages/texture/in_render_misc.spec.ts index db18a0140fb0..37f58b65651a 100644 --- a/src/webgpu/api/validation/resource_usages/texture/in_render_misc.spec.ts +++ b/src/webgpu/api/validation/resource_usages/texture/in_render_misc.spec.ts @@ -15,7 +15,7 @@ class F extends ValidationTest { createBindGroupLayoutForTest( textureUsage: TextureBindingType, sampleType: 'unfilterable-float' | 'depth' | 'uint', - visibility: GPUShaderStage['FRAGMENT'] | GPUShaderStage['COMPUTE'] = GPUShaderStage['FRAGMENT'] + visibility: number = GPUShaderStage.FRAGMENT ): GPUBindGroupLayout { const bindGroupLayoutEntry: GPUBindGroupLayoutEntry = { binding: 0, @@ -60,7 +60,7 @@ class F extends ValidationTest { textureView: GPUTextureView, textureUsage: TextureBindingType, sampleType: 'unfilterable-float' | 'depth' | 'uint', - visibility: GPUShaderStage['FRAGMENT'] | GPUShaderStage['COMPUTE'] = GPUShaderStage['FRAGMENT'] + visibility: number = GPUShaderStage.FRAGMENT ) { return this.device.createBindGroup({ layout: this.createBindGroupLayoutForTest(textureUsage, sampleType, visibility), diff --git a/src/webgpu/constants.ts b/src/webgpu/constants.ts index 60cdd6367455..34bce7756fe5 100644 --- a/src/webgpu/constants.ts +++ b/src/webgpu/constants.ts @@ -15,7 +15,7 @@ const BufferUsage = { INDIRECT: 0x0100, QUERY_RESOLVE: 0x0200, } as const; -checkType>(BufferUsage); +checkType(BufferUsage); const TextureUsage = { COPY_SRC: 0x01, @@ -26,7 +26,7 @@ const TextureUsage = { STORAGE: 0x08, RENDER_ATTACHMENT: 0x10, } as const; -checkType>(TextureUsage); +checkType(TextureUsage); const ColorWrite = { RED: 0x1, @@ -35,20 +35,20 @@ const ColorWrite = { ALPHA: 0x8, ALL: 0xf, } as const; -checkType>(ColorWrite); +checkType(ColorWrite); const ShaderStage = { VERTEX: 0x1, FRAGMENT: 0x2, COMPUTE: 0x4, } as const; -checkType>(ShaderStage); +checkType(ShaderStage); const MapMode = { READ: 0x1, WRITE: 0x2, } as const; -checkType>(MapMode); +checkType(MapMode); export const GPUConst = { BufferUsage,