@types/sharedworker 0.0.215 → 0.0.217
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +1 -1
- package/index.d.ts +112 -1
- package/package.json +1 -1
- package/ts5.5/index.d.ts +112 -1
- package/ts5.6/index.d.ts +112 -1
- package/ts5.9/index.d.ts +112 -1
package/README.md
CHANGED
|
@@ -28,4 +28,4 @@ This project does not respect semantic versioning as almost every change could p
|
|
|
28
28
|
|
|
29
29
|
## Deploy Metadata
|
|
30
30
|
|
|
31
|
-
You can read what changed in version 0.0.
|
|
31
|
+
You can read what changed in version 0.0.217 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fsharedworker%400.0.217.
|
package/index.d.ts
CHANGED
|
@@ -235,6 +235,12 @@ interface GPUBufferBinding {
|
|
|
235
235
|
size?: GPUSize64;
|
|
236
236
|
}
|
|
237
237
|
|
|
238
|
+
interface GPUBufferDescriptor extends GPUObjectDescriptorBase {
|
|
239
|
+
mappedAtCreation?: boolean;
|
|
240
|
+
size: GPUSize64;
|
|
241
|
+
usage: GPUBufferUsageFlags;
|
|
242
|
+
}
|
|
243
|
+
|
|
238
244
|
interface GPUCanvasConfiguration {
|
|
239
245
|
alphaMode?: GPUCanvasAlphaMode;
|
|
240
246
|
colorSpace?: PredefinedColorSpace;
|
|
@@ -259,6 +265,9 @@ interface GPUColorDict {
|
|
|
259
265
|
interface GPUCommandBufferDescriptor extends GPUObjectDescriptorBase {
|
|
260
266
|
}
|
|
261
267
|
|
|
268
|
+
interface GPUCommandEncoderDescriptor extends GPUObjectDescriptorBase {
|
|
269
|
+
}
|
|
270
|
+
|
|
262
271
|
interface GPUComputePassDescriptor extends GPUObjectDescriptorBase {
|
|
263
272
|
timestampWrites?: GPUComputePassTimestampWrites;
|
|
264
273
|
}
|
|
@@ -269,6 +278,10 @@ interface GPUComputePassTimestampWrites {
|
|
|
269
278
|
querySet: GPUQuerySet;
|
|
270
279
|
}
|
|
271
280
|
|
|
281
|
+
interface GPUComputePipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
282
|
+
compute: GPUProgrammableStage;
|
|
283
|
+
}
|
|
284
|
+
|
|
272
285
|
interface GPUCopyExternalImageDestInfo extends GPUTexelCopyTextureInfo {
|
|
273
286
|
colorSpace?: PredefinedColorSpace;
|
|
274
287
|
premultipliedAlpha?: boolean;
|
|
@@ -305,13 +318,37 @@ interface GPUOrigin3DDict {
|
|
|
305
318
|
z?: GPUIntegerCoordinate;
|
|
306
319
|
}
|
|
307
320
|
|
|
321
|
+
interface GPUPipelineDescriptorBase extends GPUObjectDescriptorBase {
|
|
322
|
+
layout: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
323
|
+
}
|
|
324
|
+
|
|
308
325
|
interface GPUPipelineErrorInit {
|
|
309
326
|
reason: GPUPipelineErrorReason;
|
|
310
327
|
}
|
|
311
328
|
|
|
329
|
+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
|
|
330
|
+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
|
|
331
|
+
}
|
|
332
|
+
|
|
333
|
+
interface GPUProgrammableStage {
|
|
334
|
+
constants?: Record<string, GPUPipelineConstantValue>;
|
|
335
|
+
entryPoint?: string;
|
|
336
|
+
module: GPUShaderModule;
|
|
337
|
+
}
|
|
338
|
+
|
|
339
|
+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
|
|
340
|
+
count: GPUSize32;
|
|
341
|
+
type: GPUQueryType;
|
|
342
|
+
}
|
|
343
|
+
|
|
312
344
|
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
|
|
313
345
|
}
|
|
314
346
|
|
|
347
|
+
interface GPURenderBundleEncoderDescriptor extends GPURenderPassLayout {
|
|
348
|
+
depthReadOnly?: boolean;
|
|
349
|
+
stencilReadOnly?: boolean;
|
|
350
|
+
}
|
|
351
|
+
|
|
315
352
|
interface GPURenderPassColorAttachment {
|
|
316
353
|
clearValue?: GPUColor;
|
|
317
354
|
depthSlice?: GPUIntegerCoordinate;
|
|
@@ -341,12 +378,31 @@ interface GPURenderPassDescriptor extends GPUObjectDescriptorBase {
|
|
|
341
378
|
timestampWrites?: GPURenderPassTimestampWrites;
|
|
342
379
|
}
|
|
343
380
|
|
|
381
|
+
interface GPURenderPassLayout extends GPUObjectDescriptorBase {
|
|
382
|
+
colorFormats: (GPUTextureFormat | null)[];
|
|
383
|
+
depthStencilFormat?: GPUTextureFormat;
|
|
384
|
+
sampleCount?: GPUSize32;
|
|
385
|
+
}
|
|
386
|
+
|
|
344
387
|
interface GPURenderPassTimestampWrites {
|
|
345
388
|
beginningOfPassWriteIndex?: GPUSize32;
|
|
346
389
|
endOfPassWriteIndex?: GPUSize32;
|
|
347
390
|
querySet: GPUQuerySet;
|
|
348
391
|
}
|
|
349
392
|
|
|
393
|
+
interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
394
|
+
addressModeU?: GPUAddressMode;
|
|
395
|
+
addressModeV?: GPUAddressMode;
|
|
396
|
+
addressModeW?: GPUAddressMode;
|
|
397
|
+
compare?: GPUCompareFunction;
|
|
398
|
+
lodMaxClamp?: number;
|
|
399
|
+
lodMinClamp?: number;
|
|
400
|
+
magFilter?: GPUFilterMode;
|
|
401
|
+
maxAnisotropy?: number;
|
|
402
|
+
minFilter?: GPUFilterMode;
|
|
403
|
+
mipmapFilter?: GPUMipmapFilterMode;
|
|
404
|
+
}
|
|
405
|
+
|
|
350
406
|
interface GPUTexelCopyBufferInfo extends GPUTexelCopyBufferLayout {
|
|
351
407
|
buffer: GPUBuffer;
|
|
352
408
|
}
|
|
@@ -4473,6 +4529,54 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
|
|
|
4473
4529
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBindGroup)
|
|
4474
4530
|
*/
|
|
4475
4531
|
createBindGroup(descriptor: GPUBindGroupDescriptor): GPUBindGroup;
|
|
4532
|
+
/**
|
|
4533
|
+
* The **`createBuffer()`** method of the GPUDevice interface creates a GPUBuffer in which to store raw data to use in GPU operations.
|
|
4534
|
+
*
|
|
4535
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBuffer)
|
|
4536
|
+
*/
|
|
4537
|
+
createBuffer(descriptor: GPUBufferDescriptor): GPUBuffer;
|
|
4538
|
+
/**
|
|
4539
|
+
* The **`createCommandEncoder()`** method of the GPUDevice interface creates a GPUCommandEncoder, used to encode commands to be issued to the GPU.
|
|
4540
|
+
*
|
|
4541
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createCommandEncoder)
|
|
4542
|
+
*/
|
|
4543
|
+
createCommandEncoder(descriptor?: GPUCommandEncoderDescriptor): GPUCommandEncoder;
|
|
4544
|
+
/**
|
|
4545
|
+
* The **`createComputePipeline()`** method of the GPUDevice interface creates a GPUComputePipeline that can control the compute shader stage and be used in a GPUComputePassEncoder.
|
|
4546
|
+
*
|
|
4547
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipeline)
|
|
4548
|
+
*/
|
|
4549
|
+
createComputePipeline(descriptor: GPUComputePipelineDescriptor): GPUComputePipeline;
|
|
4550
|
+
/**
|
|
4551
|
+
* The **`createComputePipelineAsync()`** method of the GPUDevice interface returns a Promise that fulfills with a GPUComputePipeline, which can control the compute shader stage and be used in a GPUComputePassEncoder, once the pipeline can be used without any stalling.
|
|
4552
|
+
*
|
|
4553
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
|
|
4554
|
+
*/
|
|
4555
|
+
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
|
|
4556
|
+
/**
|
|
4557
|
+
* The **`createPipelineLayout()`** method of the GPUDevice interface creates a GPUPipelineLayout that defines the GPUBindGroupLayouts used by a pipeline. GPUBindGroups used with the pipeline during command encoding must have compatible GPUBindGroupLayouts.
|
|
4558
|
+
*
|
|
4559
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
|
|
4560
|
+
*/
|
|
4561
|
+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
|
|
4562
|
+
/**
|
|
4563
|
+
* The **`createQuerySet()`** method of the GPUDevice interface creates a GPUQuerySet that can be used to record the results of queries on passes, such as occlusion or timestamp queries.
|
|
4564
|
+
*
|
|
4565
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
|
|
4566
|
+
*/
|
|
4567
|
+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
|
|
4568
|
+
/**
|
|
4569
|
+
* The **`createRenderBundleEncoder()`** method of the GPUDevice interface creates a GPURenderBundleEncoder that can be used to pre-record bundles of commands. These can be reused in GPURenderPassEncoders via the executeBundles() method, as many times as required.
|
|
4570
|
+
*
|
|
4571
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createRenderBundleEncoder)
|
|
4572
|
+
*/
|
|
4573
|
+
createRenderBundleEncoder(descriptor: GPURenderBundleEncoderDescriptor): GPURenderBundleEncoder;
|
|
4574
|
+
/**
|
|
4575
|
+
* The **`createSampler()`** method of the GPUDevice interface creates a GPUSampler, which controls how shaders transform and filter texture resource data.
|
|
4576
|
+
*
|
|
4577
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createSampler)
|
|
4578
|
+
*/
|
|
4579
|
+
createSampler(descriptor?: GPUSamplerDescriptor): GPUSampler;
|
|
4476
4580
|
/**
|
|
4477
4581
|
* The **`destroy()`** method of the GPUDevice interface destroys the device, preventing further operations on it.
|
|
4478
4582
|
*
|
|
@@ -12061,7 +12165,7 @@ declare namespace WebAssembly {
|
|
|
12061
12165
|
*
|
|
12062
12166
|
* [MDN Reference](https://developer.mozilla.org/docs/WebAssembly/Reference/JavaScript_interface/Exception/getArg)
|
|
12063
12167
|
*/
|
|
12064
|
-
getArg(index: number): any;
|
|
12168
|
+
getArg(exceptionTag: Tag, index: number): any;
|
|
12065
12169
|
/**
|
|
12066
12170
|
* The **`is()`** prototype method of the Exception object can be used to test if the Exception matches a given tag.
|
|
12067
12171
|
*
|
|
@@ -12656,6 +12760,7 @@ type GLuint = number;
|
|
|
12656
12760
|
type GLuint64 = number;
|
|
12657
12761
|
type GPUBindingResource = GPUSampler | GPUTexture | GPUTextureView | GPUBuffer | GPUBufferBinding | GPUExternalTexture;
|
|
12658
12762
|
type GPUBufferDynamicOffset = number;
|
|
12763
|
+
type GPUBufferUsageFlags = number;
|
|
12659
12764
|
type GPUColor = number[] | GPUColorDict;
|
|
12660
12765
|
type GPUCopyExternalImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
12661
12766
|
type GPUExtent3D = GPUIntegerCoordinate[] | GPUExtent3DDict;
|
|
@@ -12666,6 +12771,7 @@ type GPUIntegerCoordinateOut = number;
|
|
|
12666
12771
|
type GPUMapModeFlags = number;
|
|
12667
12772
|
type GPUOrigin2D = GPUIntegerCoordinate[] | GPUOrigin2DDict;
|
|
12668
12773
|
type GPUOrigin3D = GPUIntegerCoordinate[] | GPUOrigin3DDict;
|
|
12774
|
+
type GPUPipelineConstantValue = number;
|
|
12669
12775
|
type GPUSignedOffset32 = number;
|
|
12670
12776
|
type GPUSize32 = number;
|
|
12671
12777
|
type GPUSize32Out = number;
|
|
@@ -12717,14 +12823,19 @@ type FileSystemHandleKind = "directory" | "file";
|
|
|
12717
12823
|
type FontDisplay = "auto" | "block" | "fallback" | "optional" | "swap";
|
|
12718
12824
|
type FontFaceLoadStatus = "error" | "loaded" | "loading" | "unloaded";
|
|
12719
12825
|
type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
12826
|
+
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
12827
|
+
type GPUAutoLayoutMode = "auto";
|
|
12720
12828
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
12721
12829
|
type GPUCanvasAlphaMode = "opaque" | "premultiplied";
|
|
12722
12830
|
type GPUCanvasToneMappingMode = "extended" | "standard";
|
|
12831
|
+
type GPUCompareFunction = "always" | "equal" | "greater" | "greater-equal" | "less" | "less-equal" | "never" | "not-equal";
|
|
12723
12832
|
type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
12724
12833
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
12725
12834
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
12835
|
+
type GPUFilterMode = "linear" | "nearest";
|
|
12726
12836
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
12727
12837
|
type GPULoadOp = "clear" | "load";
|
|
12838
|
+
type GPUMipmapFilterMode = "linear" | "nearest";
|
|
12728
12839
|
type GPUPipelineErrorReason = "internal" | "validation";
|
|
12729
12840
|
type GPUQueryType = "occlusion" | "timestamp";
|
|
12730
12841
|
type GPUStoreOp = "discard" | "store";
|
package/package.json
CHANGED
package/ts5.5/index.d.ts
CHANGED
|
@@ -232,6 +232,12 @@ interface GPUBufferBinding {
|
|
|
232
232
|
size?: GPUSize64;
|
|
233
233
|
}
|
|
234
234
|
|
|
235
|
+
interface GPUBufferDescriptor extends GPUObjectDescriptorBase {
|
|
236
|
+
mappedAtCreation?: boolean;
|
|
237
|
+
size: GPUSize64;
|
|
238
|
+
usage: GPUBufferUsageFlags;
|
|
239
|
+
}
|
|
240
|
+
|
|
235
241
|
interface GPUCanvasConfiguration {
|
|
236
242
|
alphaMode?: GPUCanvasAlphaMode;
|
|
237
243
|
colorSpace?: PredefinedColorSpace;
|
|
@@ -256,6 +262,9 @@ interface GPUColorDict {
|
|
|
256
262
|
interface GPUCommandBufferDescriptor extends GPUObjectDescriptorBase {
|
|
257
263
|
}
|
|
258
264
|
|
|
265
|
+
interface GPUCommandEncoderDescriptor extends GPUObjectDescriptorBase {
|
|
266
|
+
}
|
|
267
|
+
|
|
259
268
|
interface GPUComputePassDescriptor extends GPUObjectDescriptorBase {
|
|
260
269
|
timestampWrites?: GPUComputePassTimestampWrites;
|
|
261
270
|
}
|
|
@@ -266,6 +275,10 @@ interface GPUComputePassTimestampWrites {
|
|
|
266
275
|
querySet: GPUQuerySet;
|
|
267
276
|
}
|
|
268
277
|
|
|
278
|
+
interface GPUComputePipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
279
|
+
compute: GPUProgrammableStage;
|
|
280
|
+
}
|
|
281
|
+
|
|
269
282
|
interface GPUCopyExternalImageDestInfo extends GPUTexelCopyTextureInfo {
|
|
270
283
|
colorSpace?: PredefinedColorSpace;
|
|
271
284
|
premultipliedAlpha?: boolean;
|
|
@@ -302,13 +315,37 @@ interface GPUOrigin3DDict {
|
|
|
302
315
|
z?: GPUIntegerCoordinate;
|
|
303
316
|
}
|
|
304
317
|
|
|
318
|
+
interface GPUPipelineDescriptorBase extends GPUObjectDescriptorBase {
|
|
319
|
+
layout: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
320
|
+
}
|
|
321
|
+
|
|
305
322
|
interface GPUPipelineErrorInit {
|
|
306
323
|
reason: GPUPipelineErrorReason;
|
|
307
324
|
}
|
|
308
325
|
|
|
326
|
+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
|
|
327
|
+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
interface GPUProgrammableStage {
|
|
331
|
+
constants?: Record<string, GPUPipelineConstantValue>;
|
|
332
|
+
entryPoint?: string;
|
|
333
|
+
module: GPUShaderModule;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
|
|
337
|
+
count: GPUSize32;
|
|
338
|
+
type: GPUQueryType;
|
|
339
|
+
}
|
|
340
|
+
|
|
309
341
|
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
|
|
310
342
|
}
|
|
311
343
|
|
|
344
|
+
interface GPURenderBundleEncoderDescriptor extends GPURenderPassLayout {
|
|
345
|
+
depthReadOnly?: boolean;
|
|
346
|
+
stencilReadOnly?: boolean;
|
|
347
|
+
}
|
|
348
|
+
|
|
312
349
|
interface GPURenderPassColorAttachment {
|
|
313
350
|
clearValue?: GPUColor;
|
|
314
351
|
depthSlice?: GPUIntegerCoordinate;
|
|
@@ -338,12 +375,31 @@ interface GPURenderPassDescriptor extends GPUObjectDescriptorBase {
|
|
|
338
375
|
timestampWrites?: GPURenderPassTimestampWrites;
|
|
339
376
|
}
|
|
340
377
|
|
|
378
|
+
interface GPURenderPassLayout extends GPUObjectDescriptorBase {
|
|
379
|
+
colorFormats: (GPUTextureFormat | null)[];
|
|
380
|
+
depthStencilFormat?: GPUTextureFormat;
|
|
381
|
+
sampleCount?: GPUSize32;
|
|
382
|
+
}
|
|
383
|
+
|
|
341
384
|
interface GPURenderPassTimestampWrites {
|
|
342
385
|
beginningOfPassWriteIndex?: GPUSize32;
|
|
343
386
|
endOfPassWriteIndex?: GPUSize32;
|
|
344
387
|
querySet: GPUQuerySet;
|
|
345
388
|
}
|
|
346
389
|
|
|
390
|
+
interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
391
|
+
addressModeU?: GPUAddressMode;
|
|
392
|
+
addressModeV?: GPUAddressMode;
|
|
393
|
+
addressModeW?: GPUAddressMode;
|
|
394
|
+
compare?: GPUCompareFunction;
|
|
395
|
+
lodMaxClamp?: number;
|
|
396
|
+
lodMinClamp?: number;
|
|
397
|
+
magFilter?: GPUFilterMode;
|
|
398
|
+
maxAnisotropy?: number;
|
|
399
|
+
minFilter?: GPUFilterMode;
|
|
400
|
+
mipmapFilter?: GPUMipmapFilterMode;
|
|
401
|
+
}
|
|
402
|
+
|
|
347
403
|
interface GPUTexelCopyBufferInfo extends GPUTexelCopyBufferLayout {
|
|
348
404
|
buffer: GPUBuffer;
|
|
349
405
|
}
|
|
@@ -4470,6 +4526,54 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
|
|
|
4470
4526
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBindGroup)
|
|
4471
4527
|
*/
|
|
4472
4528
|
createBindGroup(descriptor: GPUBindGroupDescriptor): GPUBindGroup;
|
|
4529
|
+
/**
|
|
4530
|
+
* The **`createBuffer()`** method of the GPUDevice interface creates a GPUBuffer in which to store raw data to use in GPU operations.
|
|
4531
|
+
*
|
|
4532
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBuffer)
|
|
4533
|
+
*/
|
|
4534
|
+
createBuffer(descriptor: GPUBufferDescriptor): GPUBuffer;
|
|
4535
|
+
/**
|
|
4536
|
+
* The **`createCommandEncoder()`** method of the GPUDevice interface creates a GPUCommandEncoder, used to encode commands to be issued to the GPU.
|
|
4537
|
+
*
|
|
4538
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createCommandEncoder)
|
|
4539
|
+
*/
|
|
4540
|
+
createCommandEncoder(descriptor?: GPUCommandEncoderDescriptor): GPUCommandEncoder;
|
|
4541
|
+
/**
|
|
4542
|
+
* The **`createComputePipeline()`** method of the GPUDevice interface creates a GPUComputePipeline that can control the compute shader stage and be used in a GPUComputePassEncoder.
|
|
4543
|
+
*
|
|
4544
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipeline)
|
|
4545
|
+
*/
|
|
4546
|
+
createComputePipeline(descriptor: GPUComputePipelineDescriptor): GPUComputePipeline;
|
|
4547
|
+
/**
|
|
4548
|
+
* The **`createComputePipelineAsync()`** method of the GPUDevice interface returns a Promise that fulfills with a GPUComputePipeline, which can control the compute shader stage and be used in a GPUComputePassEncoder, once the pipeline can be used without any stalling.
|
|
4549
|
+
*
|
|
4550
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
|
|
4551
|
+
*/
|
|
4552
|
+
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
|
|
4553
|
+
/**
|
|
4554
|
+
* The **`createPipelineLayout()`** method of the GPUDevice interface creates a GPUPipelineLayout that defines the GPUBindGroupLayouts used by a pipeline. GPUBindGroups used with the pipeline during command encoding must have compatible GPUBindGroupLayouts.
|
|
4555
|
+
*
|
|
4556
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
|
|
4557
|
+
*/
|
|
4558
|
+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
|
|
4559
|
+
/**
|
|
4560
|
+
* The **`createQuerySet()`** method of the GPUDevice interface creates a GPUQuerySet that can be used to record the results of queries on passes, such as occlusion or timestamp queries.
|
|
4561
|
+
*
|
|
4562
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
|
|
4563
|
+
*/
|
|
4564
|
+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
|
|
4565
|
+
/**
|
|
4566
|
+
* The **`createRenderBundleEncoder()`** method of the GPUDevice interface creates a GPURenderBundleEncoder that can be used to pre-record bundles of commands. These can be reused in GPURenderPassEncoders via the executeBundles() method, as many times as required.
|
|
4567
|
+
*
|
|
4568
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createRenderBundleEncoder)
|
|
4569
|
+
*/
|
|
4570
|
+
createRenderBundleEncoder(descriptor: GPURenderBundleEncoderDescriptor): GPURenderBundleEncoder;
|
|
4571
|
+
/**
|
|
4572
|
+
* The **`createSampler()`** method of the GPUDevice interface creates a GPUSampler, which controls how shaders transform and filter texture resource data.
|
|
4573
|
+
*
|
|
4574
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createSampler)
|
|
4575
|
+
*/
|
|
4576
|
+
createSampler(descriptor?: GPUSamplerDescriptor): GPUSampler;
|
|
4473
4577
|
/**
|
|
4474
4578
|
* The **`destroy()`** method of the GPUDevice interface destroys the device, preventing further operations on it.
|
|
4475
4579
|
*
|
|
@@ -12058,7 +12162,7 @@ declare namespace WebAssembly {
|
|
|
12058
12162
|
*
|
|
12059
12163
|
* [MDN Reference](https://developer.mozilla.org/docs/WebAssembly/Reference/JavaScript_interface/Exception/getArg)
|
|
12060
12164
|
*/
|
|
12061
|
-
getArg(index: number): any;
|
|
12165
|
+
getArg(exceptionTag: Tag, index: number): any;
|
|
12062
12166
|
/**
|
|
12063
12167
|
* The **`is()`** prototype method of the Exception object can be used to test if the Exception matches a given tag.
|
|
12064
12168
|
*
|
|
@@ -12653,6 +12757,7 @@ type GLuint = number;
|
|
|
12653
12757
|
type GLuint64 = number;
|
|
12654
12758
|
type GPUBindingResource = GPUSampler | GPUTexture | GPUTextureView | GPUBuffer | GPUBufferBinding | GPUExternalTexture;
|
|
12655
12759
|
type GPUBufferDynamicOffset = number;
|
|
12760
|
+
type GPUBufferUsageFlags = number;
|
|
12656
12761
|
type GPUColor = number[] | GPUColorDict;
|
|
12657
12762
|
type GPUCopyExternalImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
12658
12763
|
type GPUExtent3D = GPUIntegerCoordinate[] | GPUExtent3DDict;
|
|
@@ -12663,6 +12768,7 @@ type GPUIntegerCoordinateOut = number;
|
|
|
12663
12768
|
type GPUMapModeFlags = number;
|
|
12664
12769
|
type GPUOrigin2D = GPUIntegerCoordinate[] | GPUOrigin2DDict;
|
|
12665
12770
|
type GPUOrigin3D = GPUIntegerCoordinate[] | GPUOrigin3DDict;
|
|
12771
|
+
type GPUPipelineConstantValue = number;
|
|
12666
12772
|
type GPUSignedOffset32 = number;
|
|
12667
12773
|
type GPUSize32 = number;
|
|
12668
12774
|
type GPUSize32Out = number;
|
|
@@ -12714,14 +12820,19 @@ type FileSystemHandleKind = "directory" | "file";
|
|
|
12714
12820
|
type FontDisplay = "auto" | "block" | "fallback" | "optional" | "swap";
|
|
12715
12821
|
type FontFaceLoadStatus = "error" | "loaded" | "loading" | "unloaded";
|
|
12716
12822
|
type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
12823
|
+
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
12824
|
+
type GPUAutoLayoutMode = "auto";
|
|
12717
12825
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
12718
12826
|
type GPUCanvasAlphaMode = "opaque" | "premultiplied";
|
|
12719
12827
|
type GPUCanvasToneMappingMode = "extended" | "standard";
|
|
12828
|
+
type GPUCompareFunction = "always" | "equal" | "greater" | "greater-equal" | "less" | "less-equal" | "never" | "not-equal";
|
|
12720
12829
|
type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
12721
12830
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
12722
12831
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
12832
|
+
type GPUFilterMode = "linear" | "nearest";
|
|
12723
12833
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
12724
12834
|
type GPULoadOp = "clear" | "load";
|
|
12835
|
+
type GPUMipmapFilterMode = "linear" | "nearest";
|
|
12725
12836
|
type GPUPipelineErrorReason = "internal" | "validation";
|
|
12726
12837
|
type GPUQueryType = "occlusion" | "timestamp";
|
|
12727
12838
|
type GPUStoreOp = "discard" | "store";
|
package/ts5.6/index.d.ts
CHANGED
|
@@ -232,6 +232,12 @@ interface GPUBufferBinding {
|
|
|
232
232
|
size?: GPUSize64;
|
|
233
233
|
}
|
|
234
234
|
|
|
235
|
+
interface GPUBufferDescriptor extends GPUObjectDescriptorBase {
|
|
236
|
+
mappedAtCreation?: boolean;
|
|
237
|
+
size: GPUSize64;
|
|
238
|
+
usage: GPUBufferUsageFlags;
|
|
239
|
+
}
|
|
240
|
+
|
|
235
241
|
interface GPUCanvasConfiguration {
|
|
236
242
|
alphaMode?: GPUCanvasAlphaMode;
|
|
237
243
|
colorSpace?: PredefinedColorSpace;
|
|
@@ -256,6 +262,9 @@ interface GPUColorDict {
|
|
|
256
262
|
interface GPUCommandBufferDescriptor extends GPUObjectDescriptorBase {
|
|
257
263
|
}
|
|
258
264
|
|
|
265
|
+
interface GPUCommandEncoderDescriptor extends GPUObjectDescriptorBase {
|
|
266
|
+
}
|
|
267
|
+
|
|
259
268
|
interface GPUComputePassDescriptor extends GPUObjectDescriptorBase {
|
|
260
269
|
timestampWrites?: GPUComputePassTimestampWrites;
|
|
261
270
|
}
|
|
@@ -266,6 +275,10 @@ interface GPUComputePassTimestampWrites {
|
|
|
266
275
|
querySet: GPUQuerySet;
|
|
267
276
|
}
|
|
268
277
|
|
|
278
|
+
interface GPUComputePipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
279
|
+
compute: GPUProgrammableStage;
|
|
280
|
+
}
|
|
281
|
+
|
|
269
282
|
interface GPUCopyExternalImageDestInfo extends GPUTexelCopyTextureInfo {
|
|
270
283
|
colorSpace?: PredefinedColorSpace;
|
|
271
284
|
premultipliedAlpha?: boolean;
|
|
@@ -302,13 +315,37 @@ interface GPUOrigin3DDict {
|
|
|
302
315
|
z?: GPUIntegerCoordinate;
|
|
303
316
|
}
|
|
304
317
|
|
|
318
|
+
interface GPUPipelineDescriptorBase extends GPUObjectDescriptorBase {
|
|
319
|
+
layout: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
320
|
+
}
|
|
321
|
+
|
|
305
322
|
interface GPUPipelineErrorInit {
|
|
306
323
|
reason: GPUPipelineErrorReason;
|
|
307
324
|
}
|
|
308
325
|
|
|
326
|
+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
|
|
327
|
+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
interface GPUProgrammableStage {
|
|
331
|
+
constants?: Record<string, GPUPipelineConstantValue>;
|
|
332
|
+
entryPoint?: string;
|
|
333
|
+
module: GPUShaderModule;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
|
|
337
|
+
count: GPUSize32;
|
|
338
|
+
type: GPUQueryType;
|
|
339
|
+
}
|
|
340
|
+
|
|
309
341
|
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
|
|
310
342
|
}
|
|
311
343
|
|
|
344
|
+
interface GPURenderBundleEncoderDescriptor extends GPURenderPassLayout {
|
|
345
|
+
depthReadOnly?: boolean;
|
|
346
|
+
stencilReadOnly?: boolean;
|
|
347
|
+
}
|
|
348
|
+
|
|
312
349
|
interface GPURenderPassColorAttachment {
|
|
313
350
|
clearValue?: GPUColor;
|
|
314
351
|
depthSlice?: GPUIntegerCoordinate;
|
|
@@ -338,12 +375,31 @@ interface GPURenderPassDescriptor extends GPUObjectDescriptorBase {
|
|
|
338
375
|
timestampWrites?: GPURenderPassTimestampWrites;
|
|
339
376
|
}
|
|
340
377
|
|
|
378
|
+
interface GPURenderPassLayout extends GPUObjectDescriptorBase {
|
|
379
|
+
colorFormats: (GPUTextureFormat | null)[];
|
|
380
|
+
depthStencilFormat?: GPUTextureFormat;
|
|
381
|
+
sampleCount?: GPUSize32;
|
|
382
|
+
}
|
|
383
|
+
|
|
341
384
|
interface GPURenderPassTimestampWrites {
|
|
342
385
|
beginningOfPassWriteIndex?: GPUSize32;
|
|
343
386
|
endOfPassWriteIndex?: GPUSize32;
|
|
344
387
|
querySet: GPUQuerySet;
|
|
345
388
|
}
|
|
346
389
|
|
|
390
|
+
interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
391
|
+
addressModeU?: GPUAddressMode;
|
|
392
|
+
addressModeV?: GPUAddressMode;
|
|
393
|
+
addressModeW?: GPUAddressMode;
|
|
394
|
+
compare?: GPUCompareFunction;
|
|
395
|
+
lodMaxClamp?: number;
|
|
396
|
+
lodMinClamp?: number;
|
|
397
|
+
magFilter?: GPUFilterMode;
|
|
398
|
+
maxAnisotropy?: number;
|
|
399
|
+
minFilter?: GPUFilterMode;
|
|
400
|
+
mipmapFilter?: GPUMipmapFilterMode;
|
|
401
|
+
}
|
|
402
|
+
|
|
347
403
|
interface GPUTexelCopyBufferInfo extends GPUTexelCopyBufferLayout {
|
|
348
404
|
buffer: GPUBuffer;
|
|
349
405
|
}
|
|
@@ -4470,6 +4526,54 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
|
|
|
4470
4526
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBindGroup)
|
|
4471
4527
|
*/
|
|
4472
4528
|
createBindGroup(descriptor: GPUBindGroupDescriptor): GPUBindGroup;
|
|
4529
|
+
/**
|
|
4530
|
+
* The **`createBuffer()`** method of the GPUDevice interface creates a GPUBuffer in which to store raw data to use in GPU operations.
|
|
4531
|
+
*
|
|
4532
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBuffer)
|
|
4533
|
+
*/
|
|
4534
|
+
createBuffer(descriptor: GPUBufferDescriptor): GPUBuffer;
|
|
4535
|
+
/**
|
|
4536
|
+
* The **`createCommandEncoder()`** method of the GPUDevice interface creates a GPUCommandEncoder, used to encode commands to be issued to the GPU.
|
|
4537
|
+
*
|
|
4538
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createCommandEncoder)
|
|
4539
|
+
*/
|
|
4540
|
+
createCommandEncoder(descriptor?: GPUCommandEncoderDescriptor): GPUCommandEncoder;
|
|
4541
|
+
/**
|
|
4542
|
+
* The **`createComputePipeline()`** method of the GPUDevice interface creates a GPUComputePipeline that can control the compute shader stage and be used in a GPUComputePassEncoder.
|
|
4543
|
+
*
|
|
4544
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipeline)
|
|
4545
|
+
*/
|
|
4546
|
+
createComputePipeline(descriptor: GPUComputePipelineDescriptor): GPUComputePipeline;
|
|
4547
|
+
/**
|
|
4548
|
+
* The **`createComputePipelineAsync()`** method of the GPUDevice interface returns a Promise that fulfills with a GPUComputePipeline, which can control the compute shader stage and be used in a GPUComputePassEncoder, once the pipeline can be used without any stalling.
|
|
4549
|
+
*
|
|
4550
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
|
|
4551
|
+
*/
|
|
4552
|
+
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
|
|
4553
|
+
/**
|
|
4554
|
+
* The **`createPipelineLayout()`** method of the GPUDevice interface creates a GPUPipelineLayout that defines the GPUBindGroupLayouts used by a pipeline. GPUBindGroups used with the pipeline during command encoding must have compatible GPUBindGroupLayouts.
|
|
4555
|
+
*
|
|
4556
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
|
|
4557
|
+
*/
|
|
4558
|
+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
|
|
4559
|
+
/**
|
|
4560
|
+
* The **`createQuerySet()`** method of the GPUDevice interface creates a GPUQuerySet that can be used to record the results of queries on passes, such as occlusion or timestamp queries.
|
|
4561
|
+
*
|
|
4562
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
|
|
4563
|
+
*/
|
|
4564
|
+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
|
|
4565
|
+
/**
|
|
4566
|
+
* The **`createRenderBundleEncoder()`** method of the GPUDevice interface creates a GPURenderBundleEncoder that can be used to pre-record bundles of commands. These can be reused in GPURenderPassEncoders via the executeBundles() method, as many times as required.
|
|
4567
|
+
*
|
|
4568
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createRenderBundleEncoder)
|
|
4569
|
+
*/
|
|
4570
|
+
createRenderBundleEncoder(descriptor: GPURenderBundleEncoderDescriptor): GPURenderBundleEncoder;
|
|
4571
|
+
/**
|
|
4572
|
+
* The **`createSampler()`** method of the GPUDevice interface creates a GPUSampler, which controls how shaders transform and filter texture resource data.
|
|
4573
|
+
*
|
|
4574
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createSampler)
|
|
4575
|
+
*/
|
|
4576
|
+
createSampler(descriptor?: GPUSamplerDescriptor): GPUSampler;
|
|
4473
4577
|
/**
|
|
4474
4578
|
* The **`destroy()`** method of the GPUDevice interface destroys the device, preventing further operations on it.
|
|
4475
4579
|
*
|
|
@@ -12058,7 +12162,7 @@ declare namespace WebAssembly {
|
|
|
12058
12162
|
*
|
|
12059
12163
|
* [MDN Reference](https://developer.mozilla.org/docs/WebAssembly/Reference/JavaScript_interface/Exception/getArg)
|
|
12060
12164
|
*/
|
|
12061
|
-
getArg(index: number): any;
|
|
12165
|
+
getArg(exceptionTag: Tag, index: number): any;
|
|
12062
12166
|
/**
|
|
12063
12167
|
* The **`is()`** prototype method of the Exception object can be used to test if the Exception matches a given tag.
|
|
12064
12168
|
*
|
|
@@ -12653,6 +12757,7 @@ type GLuint = number;
|
|
|
12653
12757
|
type GLuint64 = number;
|
|
12654
12758
|
type GPUBindingResource = GPUSampler | GPUTexture | GPUTextureView | GPUBuffer | GPUBufferBinding | GPUExternalTexture;
|
|
12655
12759
|
type GPUBufferDynamicOffset = number;
|
|
12760
|
+
type GPUBufferUsageFlags = number;
|
|
12656
12761
|
type GPUColor = number[] | GPUColorDict;
|
|
12657
12762
|
type GPUCopyExternalImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
12658
12763
|
type GPUExtent3D = GPUIntegerCoordinate[] | GPUExtent3DDict;
|
|
@@ -12663,6 +12768,7 @@ type GPUIntegerCoordinateOut = number;
|
|
|
12663
12768
|
type GPUMapModeFlags = number;
|
|
12664
12769
|
type GPUOrigin2D = GPUIntegerCoordinate[] | GPUOrigin2DDict;
|
|
12665
12770
|
type GPUOrigin3D = GPUIntegerCoordinate[] | GPUOrigin3DDict;
|
|
12771
|
+
type GPUPipelineConstantValue = number;
|
|
12666
12772
|
type GPUSignedOffset32 = number;
|
|
12667
12773
|
type GPUSize32 = number;
|
|
12668
12774
|
type GPUSize32Out = number;
|
|
@@ -12714,14 +12820,19 @@ type FileSystemHandleKind = "directory" | "file";
|
|
|
12714
12820
|
type FontDisplay = "auto" | "block" | "fallback" | "optional" | "swap";
|
|
12715
12821
|
type FontFaceLoadStatus = "error" | "loaded" | "loading" | "unloaded";
|
|
12716
12822
|
type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
12823
|
+
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
12824
|
+
type GPUAutoLayoutMode = "auto";
|
|
12717
12825
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
12718
12826
|
type GPUCanvasAlphaMode = "opaque" | "premultiplied";
|
|
12719
12827
|
type GPUCanvasToneMappingMode = "extended" | "standard";
|
|
12828
|
+
type GPUCompareFunction = "always" | "equal" | "greater" | "greater-equal" | "less" | "less-equal" | "never" | "not-equal";
|
|
12720
12829
|
type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
12721
12830
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
12722
12831
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
12832
|
+
type GPUFilterMode = "linear" | "nearest";
|
|
12723
12833
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
12724
12834
|
type GPULoadOp = "clear" | "load";
|
|
12835
|
+
type GPUMipmapFilterMode = "linear" | "nearest";
|
|
12725
12836
|
type GPUPipelineErrorReason = "internal" | "validation";
|
|
12726
12837
|
type GPUQueryType = "occlusion" | "timestamp";
|
|
12727
12838
|
type GPUStoreOp = "discard" | "store";
|
package/ts5.9/index.d.ts
CHANGED
|
@@ -232,6 +232,12 @@ interface GPUBufferBinding {
|
|
|
232
232
|
size?: GPUSize64;
|
|
233
233
|
}
|
|
234
234
|
|
|
235
|
+
interface GPUBufferDescriptor extends GPUObjectDescriptorBase {
|
|
236
|
+
mappedAtCreation?: boolean;
|
|
237
|
+
size: GPUSize64;
|
|
238
|
+
usage: GPUBufferUsageFlags;
|
|
239
|
+
}
|
|
240
|
+
|
|
235
241
|
interface GPUCanvasConfiguration {
|
|
236
242
|
alphaMode?: GPUCanvasAlphaMode;
|
|
237
243
|
colorSpace?: PredefinedColorSpace;
|
|
@@ -256,6 +262,9 @@ interface GPUColorDict {
|
|
|
256
262
|
interface GPUCommandBufferDescriptor extends GPUObjectDescriptorBase {
|
|
257
263
|
}
|
|
258
264
|
|
|
265
|
+
interface GPUCommandEncoderDescriptor extends GPUObjectDescriptorBase {
|
|
266
|
+
}
|
|
267
|
+
|
|
259
268
|
interface GPUComputePassDescriptor extends GPUObjectDescriptorBase {
|
|
260
269
|
timestampWrites?: GPUComputePassTimestampWrites;
|
|
261
270
|
}
|
|
@@ -266,6 +275,10 @@ interface GPUComputePassTimestampWrites {
|
|
|
266
275
|
querySet: GPUQuerySet;
|
|
267
276
|
}
|
|
268
277
|
|
|
278
|
+
interface GPUComputePipelineDescriptor extends GPUPipelineDescriptorBase {
|
|
279
|
+
compute: GPUProgrammableStage;
|
|
280
|
+
}
|
|
281
|
+
|
|
269
282
|
interface GPUCopyExternalImageDestInfo extends GPUTexelCopyTextureInfo {
|
|
270
283
|
colorSpace?: PredefinedColorSpace;
|
|
271
284
|
premultipliedAlpha?: boolean;
|
|
@@ -302,13 +315,37 @@ interface GPUOrigin3DDict {
|
|
|
302
315
|
z?: GPUIntegerCoordinate;
|
|
303
316
|
}
|
|
304
317
|
|
|
318
|
+
interface GPUPipelineDescriptorBase extends GPUObjectDescriptorBase {
|
|
319
|
+
layout: GPUPipelineLayout | GPUAutoLayoutMode;
|
|
320
|
+
}
|
|
321
|
+
|
|
305
322
|
interface GPUPipelineErrorInit {
|
|
306
323
|
reason: GPUPipelineErrorReason;
|
|
307
324
|
}
|
|
308
325
|
|
|
326
|
+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
|
|
327
|
+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
|
|
328
|
+
}
|
|
329
|
+
|
|
330
|
+
interface GPUProgrammableStage {
|
|
331
|
+
constants?: Record<string, GPUPipelineConstantValue>;
|
|
332
|
+
entryPoint?: string;
|
|
333
|
+
module: GPUShaderModule;
|
|
334
|
+
}
|
|
335
|
+
|
|
336
|
+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
|
|
337
|
+
count: GPUSize32;
|
|
338
|
+
type: GPUQueryType;
|
|
339
|
+
}
|
|
340
|
+
|
|
309
341
|
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
|
|
310
342
|
}
|
|
311
343
|
|
|
344
|
+
interface GPURenderBundleEncoderDescriptor extends GPURenderPassLayout {
|
|
345
|
+
depthReadOnly?: boolean;
|
|
346
|
+
stencilReadOnly?: boolean;
|
|
347
|
+
}
|
|
348
|
+
|
|
312
349
|
interface GPURenderPassColorAttachment {
|
|
313
350
|
clearValue?: GPUColor;
|
|
314
351
|
depthSlice?: GPUIntegerCoordinate;
|
|
@@ -338,12 +375,31 @@ interface GPURenderPassDescriptor extends GPUObjectDescriptorBase {
|
|
|
338
375
|
timestampWrites?: GPURenderPassTimestampWrites;
|
|
339
376
|
}
|
|
340
377
|
|
|
378
|
+
interface GPURenderPassLayout extends GPUObjectDescriptorBase {
|
|
379
|
+
colorFormats: (GPUTextureFormat | null)[];
|
|
380
|
+
depthStencilFormat?: GPUTextureFormat;
|
|
381
|
+
sampleCount?: GPUSize32;
|
|
382
|
+
}
|
|
383
|
+
|
|
341
384
|
interface GPURenderPassTimestampWrites {
|
|
342
385
|
beginningOfPassWriteIndex?: GPUSize32;
|
|
343
386
|
endOfPassWriteIndex?: GPUSize32;
|
|
344
387
|
querySet: GPUQuerySet;
|
|
345
388
|
}
|
|
346
389
|
|
|
390
|
+
interface GPUSamplerDescriptor extends GPUObjectDescriptorBase {
|
|
391
|
+
addressModeU?: GPUAddressMode;
|
|
392
|
+
addressModeV?: GPUAddressMode;
|
|
393
|
+
addressModeW?: GPUAddressMode;
|
|
394
|
+
compare?: GPUCompareFunction;
|
|
395
|
+
lodMaxClamp?: number;
|
|
396
|
+
lodMinClamp?: number;
|
|
397
|
+
magFilter?: GPUFilterMode;
|
|
398
|
+
maxAnisotropy?: number;
|
|
399
|
+
minFilter?: GPUFilterMode;
|
|
400
|
+
mipmapFilter?: GPUMipmapFilterMode;
|
|
401
|
+
}
|
|
402
|
+
|
|
347
403
|
interface GPUTexelCopyBufferInfo extends GPUTexelCopyBufferLayout {
|
|
348
404
|
buffer: GPUBuffer;
|
|
349
405
|
}
|
|
@@ -4470,6 +4526,54 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
|
|
|
4470
4526
|
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBindGroup)
|
|
4471
4527
|
*/
|
|
4472
4528
|
createBindGroup(descriptor: GPUBindGroupDescriptor): GPUBindGroup;
|
|
4529
|
+
/**
|
|
4530
|
+
* The **`createBuffer()`** method of the GPUDevice interface creates a GPUBuffer in which to store raw data to use in GPU operations.
|
|
4531
|
+
*
|
|
4532
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createBuffer)
|
|
4533
|
+
*/
|
|
4534
|
+
createBuffer(descriptor: GPUBufferDescriptor): GPUBuffer;
|
|
4535
|
+
/**
|
|
4536
|
+
* The **`createCommandEncoder()`** method of the GPUDevice interface creates a GPUCommandEncoder, used to encode commands to be issued to the GPU.
|
|
4537
|
+
*
|
|
4538
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createCommandEncoder)
|
|
4539
|
+
*/
|
|
4540
|
+
createCommandEncoder(descriptor?: GPUCommandEncoderDescriptor): GPUCommandEncoder;
|
|
4541
|
+
/**
|
|
4542
|
+
* The **`createComputePipeline()`** method of the GPUDevice interface creates a GPUComputePipeline that can control the compute shader stage and be used in a GPUComputePassEncoder.
|
|
4543
|
+
*
|
|
4544
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipeline)
|
|
4545
|
+
*/
|
|
4546
|
+
createComputePipeline(descriptor: GPUComputePipelineDescriptor): GPUComputePipeline;
|
|
4547
|
+
/**
|
|
4548
|
+
* The **`createComputePipelineAsync()`** method of the GPUDevice interface returns a Promise that fulfills with a GPUComputePipeline, which can control the compute shader stage and be used in a GPUComputePassEncoder, once the pipeline can be used without any stalling.
|
|
4549
|
+
*
|
|
4550
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
|
|
4551
|
+
*/
|
|
4552
|
+
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
|
|
4553
|
+
/**
|
|
4554
|
+
* The **`createPipelineLayout()`** method of the GPUDevice interface creates a GPUPipelineLayout that defines the GPUBindGroupLayouts used by a pipeline. GPUBindGroups used with the pipeline during command encoding must have compatible GPUBindGroupLayouts.
|
|
4555
|
+
*
|
|
4556
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
|
|
4557
|
+
*/
|
|
4558
|
+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
|
|
4559
|
+
/**
|
|
4560
|
+
* The **`createQuerySet()`** method of the GPUDevice interface creates a GPUQuerySet that can be used to record the results of queries on passes, such as occlusion or timestamp queries.
|
|
4561
|
+
*
|
|
4562
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
|
|
4563
|
+
*/
|
|
4564
|
+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
|
|
4565
|
+
/**
|
|
4566
|
+
* The **`createRenderBundleEncoder()`** method of the GPUDevice interface creates a GPURenderBundleEncoder that can be used to pre-record bundles of commands. These can be reused in GPURenderPassEncoders via the executeBundles() method, as many times as required.
|
|
4567
|
+
*
|
|
4568
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createRenderBundleEncoder)
|
|
4569
|
+
*/
|
|
4570
|
+
createRenderBundleEncoder(descriptor: GPURenderBundleEncoderDescriptor): GPURenderBundleEncoder;
|
|
4571
|
+
/**
|
|
4572
|
+
* The **`createSampler()`** method of the GPUDevice interface creates a GPUSampler, which controls how shaders transform and filter texture resource data.
|
|
4573
|
+
*
|
|
4574
|
+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createSampler)
|
|
4575
|
+
*/
|
|
4576
|
+
createSampler(descriptor?: GPUSamplerDescriptor): GPUSampler;
|
|
4473
4577
|
/**
|
|
4474
4578
|
* The **`destroy()`** method of the GPUDevice interface destroys the device, preventing further operations on it.
|
|
4475
4579
|
*
|
|
@@ -12058,7 +12162,7 @@ declare namespace WebAssembly {
|
|
|
12058
12162
|
*
|
|
12059
12163
|
* [MDN Reference](https://developer.mozilla.org/docs/WebAssembly/Reference/JavaScript_interface/Exception/getArg)
|
|
12060
12164
|
*/
|
|
12061
|
-
getArg(index: number): any;
|
|
12165
|
+
getArg(exceptionTag: Tag, index: number): any;
|
|
12062
12166
|
/**
|
|
12063
12167
|
* The **`is()`** prototype method of the Exception object can be used to test if the Exception matches a given tag.
|
|
12064
12168
|
*
|
|
@@ -12653,6 +12757,7 @@ type GLuint = number;
|
|
|
12653
12757
|
type GLuint64 = number;
|
|
12654
12758
|
type GPUBindingResource = GPUSampler | GPUTexture | GPUTextureView | GPUBuffer | GPUBufferBinding | GPUExternalTexture;
|
|
12655
12759
|
type GPUBufferDynamicOffset = number;
|
|
12760
|
+
type GPUBufferUsageFlags = number;
|
|
12656
12761
|
type GPUColor = number[] | GPUColorDict;
|
|
12657
12762
|
type GPUCopyExternalImageSource = ImageBitmap | ImageData | OffscreenCanvas;
|
|
12658
12763
|
type GPUExtent3D = GPUIntegerCoordinate[] | GPUExtent3DDict;
|
|
@@ -12663,6 +12768,7 @@ type GPUIntegerCoordinateOut = number;
|
|
|
12663
12768
|
type GPUMapModeFlags = number;
|
|
12664
12769
|
type GPUOrigin2D = GPUIntegerCoordinate[] | GPUOrigin2DDict;
|
|
12665
12770
|
type GPUOrigin3D = GPUIntegerCoordinate[] | GPUOrigin3DDict;
|
|
12771
|
+
type GPUPipelineConstantValue = number;
|
|
12666
12772
|
type GPUSignedOffset32 = number;
|
|
12667
12773
|
type GPUSize32 = number;
|
|
12668
12774
|
type GPUSize32Out = number;
|
|
@@ -12714,14 +12820,19 @@ type FileSystemHandleKind = "directory" | "file";
|
|
|
12714
12820
|
type FontDisplay = "auto" | "block" | "fallback" | "optional" | "swap";
|
|
12715
12821
|
type FontFaceLoadStatus = "error" | "loaded" | "loading" | "unloaded";
|
|
12716
12822
|
type FontFaceSetLoadStatus = "loaded" | "loading";
|
|
12823
|
+
type GPUAddressMode = "clamp-to-edge" | "mirror-repeat" | "repeat";
|
|
12824
|
+
type GPUAutoLayoutMode = "auto";
|
|
12717
12825
|
type GPUBufferMapState = "mapped" | "pending" | "unmapped";
|
|
12718
12826
|
type GPUCanvasAlphaMode = "opaque" | "premultiplied";
|
|
12719
12827
|
type GPUCanvasToneMappingMode = "extended" | "standard";
|
|
12828
|
+
type GPUCompareFunction = "always" | "equal" | "greater" | "greater-equal" | "less" | "less-equal" | "never" | "not-equal";
|
|
12720
12829
|
type GPUCompilationMessageType = "error" | "info" | "warning";
|
|
12721
12830
|
type GPUDeviceLostReason = "destroyed" | "unknown";
|
|
12722
12831
|
type GPUErrorFilter = "internal" | "out-of-memory" | "validation";
|
|
12832
|
+
type GPUFilterMode = "linear" | "nearest";
|
|
12723
12833
|
type GPUIndexFormat = "uint16" | "uint32";
|
|
12724
12834
|
type GPULoadOp = "clear" | "load";
|
|
12835
|
+
type GPUMipmapFilterMode = "linear" | "nearest";
|
|
12725
12836
|
type GPUPipelineErrorReason = "internal" | "validation";
|
|
12726
12837
|
type GPUQueryType = "occlusion" | "timestamp";
|
|
12727
12838
|
type GPUStoreOp = "discard" | "store";
|