@types/serviceworker 0.0.179 → 0.0.181

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 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.179 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fserviceworker%400.0.179.
31
+ You can read what changed in version 0.0.181 at https://github.com/microsoft/TypeScript-DOM-lib-generator/releases/tag/%40types%2Fserviceworker%400.0.181.
package/index.d.ts CHANGED
@@ -275,6 +275,13 @@ interface FontFaceSetLoadEventInit extends EventInit {
275
275
  fontfaces?: FontFace[];
276
276
  }
277
277
 
278
+ interface GPUColorDict {
279
+ a: number;
280
+ b: number;
281
+ g: number;
282
+ r: number;
283
+ }
284
+
278
285
  interface GPUObjectDescriptorBase {
279
286
  label?: string;
280
287
  }
@@ -283,6 +290,9 @@ interface GPUPipelineErrorInit {
283
290
  reason: GPUPipelineErrorReason;
284
291
  }
285
292
 
293
+ interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
294
+ }
295
+
286
296
  interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
287
297
  arrayLayerCount?: GPUIntegerCoordinate;
288
298
  aspect?: GPUTextureAspect;
@@ -4613,6 +4623,105 @@ declare var GPURenderBundle: {
4613
4623
  new(): GPURenderBundle;
4614
4624
  };
4615
4625
 
4626
+ /**
4627
+ * The **`GPURenderBundleEncoder`** interface of the WebGPU API is used to pre-record bundles of commands.
4628
+ * Available only in secure contexts.
4629
+ *
4630
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder)
4631
+ */
4632
+ interface GPURenderBundleEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4633
+ /**
4634
+ * The **`finish()`** method of the GPURenderBundleEncoder interface completes recording of the current render bundle command sequence, returning a GPURenderBundle object that can be passed into a GPURenderPassEncoder.executeBundles() call to execute those commands in a specific render pass.
4635
+ *
4636
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/finish)
4637
+ */
4638
+ finish(descriptor?: GPURenderBundleDescriptor): GPURenderBundle;
4639
+ }
4640
+
4641
+ declare var GPURenderBundleEncoder: {
4642
+ prototype: GPURenderBundleEncoder;
4643
+ new(): GPURenderBundleEncoder;
4644
+ };
4645
+
4646
+ interface GPURenderCommandsMixin {
4647
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/draw) */
4648
+ draw(vertexCount: GPUSize32, instanceCount?: GPUSize32, firstVertex?: GPUSize32, firstInstance?: GPUSize32): void;
4649
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexed) */
4650
+ drawIndexed(indexCount: GPUSize32, instanceCount?: GPUSize32, firstIndex?: GPUSize32, baseVertex?: GPUSignedOffset32, firstInstance?: GPUSize32): void;
4651
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexedIndirect) */
4652
+ drawIndexedIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4653
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndirect) */
4654
+ drawIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4655
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setIndexBuffer) */
4656
+ setIndexBuffer(buffer: GPUBuffer, indexFormat: GPUIndexFormat, offset?: GPUSize64, size?: GPUSize64): void;
4657
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setPipeline) */
4658
+ setPipeline(pipeline: GPURenderPipeline): void;
4659
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setVertexBuffer) */
4660
+ setVertexBuffer(slot: GPUIndex32, buffer: GPUBuffer | null, offset?: GPUSize64, size?: GPUSize64): void;
4661
+ }
4662
+
4663
+ /**
4664
+ * The **`GPURenderPassEncoder`** interface of the WebGPU API encodes commands related to controlling the vertex and fragment shader stages, as issued by a GPURenderPipeline. It forms part of the overall encoding activity of a GPUCommandEncoder.
4665
+ * Available only in secure contexts.
4666
+ *
4667
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder)
4668
+ */
4669
+ interface GPURenderPassEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4670
+ /**
4671
+ * The **`beginOcclusionQuery()`** method of the GPURenderPassEncoder interface begins an occlusion query at the specified index of the relevant GPUQuerySet (provided as the value of the occlusionQuerySet descriptor property when invoking GPUCommandEncoder.beginRenderPass() to run the render pass).
4672
+ *
4673
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/beginOcclusionQuery)
4674
+ */
4675
+ beginOcclusionQuery(queryIndex: GPUSize32): void;
4676
+ /**
4677
+ * The **`end()`** method of the GPURenderPassEncoder interface completes recording of the current render pass command sequence.
4678
+ *
4679
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/end)
4680
+ */
4681
+ end(): void;
4682
+ /**
4683
+ * The **`endOcclusionQuery()`** method of the GPURenderPassEncoder interface ends an active occlusion query previously started with beginOcclusionQuery().
4684
+ *
4685
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/endOcclusionQuery)
4686
+ */
4687
+ endOcclusionQuery(): void;
4688
+ /**
4689
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
4690
+ *
4691
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
4692
+ */
4693
+ executeBundles(bundles: GPURenderBundle[]): void;
4694
+ /**
4695
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
4696
+ *
4697
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
4698
+ */
4699
+ setBlendConstant(color: GPUColor): void;
4700
+ /**
4701
+ * The **`setScissorRect()`** method of the GPURenderPassEncoder interface sets the scissor rectangle used during the rasterization stage. After transformation into viewport coordinates any fragments that fall outside the scissor rectangle will be discarded.
4702
+ *
4703
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setScissorRect)
4704
+ */
4705
+ setScissorRect(x: GPUIntegerCoordinate, y: GPUIntegerCoordinate, width: GPUIntegerCoordinate, height: GPUIntegerCoordinate): void;
4706
+ /**
4707
+ * The **`setStencilReference()`** method of the GPURenderPassEncoder interface sets the stencil reference value using during stencil tests with the "replace" stencil operation (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the properties defining the various stencil operations).
4708
+ *
4709
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setStencilReference)
4710
+ */
4711
+ setStencilReference(reference: GPUStencilValue): void;
4712
+ /**
4713
+ * The **`setViewport()`** method of the GPURenderPassEncoder interface sets the viewport used during the rasterization stage to linearly map from normalized device coordinates to viewport coordinates.
4714
+ *
4715
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setViewport)
4716
+ */
4717
+ setViewport(x: number, y: number, width: number, height: number, minDepth: number, maxDepth: number): void;
4718
+ }
4719
+
4720
+ declare var GPURenderPassEncoder: {
4721
+ prototype: GPURenderPassEncoder;
4722
+ new(): GPURenderPassEncoder;
4723
+ };
4724
+
4616
4725
  /**
4617
4726
  * The **`GPURenderPipeline`** interface of the WebGPU API represents a pipeline that controls the vertex and fragment shader stages and can be used in a GPURenderPassEncoder or GPURenderBundleEncoder.
4618
4727
  * Available only in secure contexts.
@@ -11554,7 +11663,7 @@ interface WorkerGlobalScope extends EventTarget, FontFaceSource, WindowOrWorkerG
11554
11663
  */
11555
11664
  readonly self: WorkerGlobalScope & typeof globalThis;
11556
11665
  /**
11557
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
11666
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
11558
11667
  *
11559
11668
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
11560
11669
  */
@@ -12355,7 +12464,7 @@ declare var onunhandledrejection: ((this: ServiceWorkerGlobalScope, ev: PromiseR
12355
12464
  */
12356
12465
  declare var self: WorkerGlobalScope & typeof globalThis;
12357
12466
  /**
12358
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
12467
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
12359
12468
  *
12360
12469
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
12361
12470
  */
@@ -12446,15 +12555,18 @@ type GLsizeiptr = number;
12446
12555
  type GLuint = number;
12447
12556
  type GLuint64 = number;
12448
12557
  type GPUBufferDynamicOffset = number;
12558
+ type GPUColor = number[] | GPUColorDict;
12449
12559
  type GPUFlagsConstant = number;
12450
12560
  type GPUIndex32 = number;
12451
12561
  type GPUIntegerCoordinate = number;
12452
12562
  type GPUIntegerCoordinateOut = number;
12453
12563
  type GPUMapModeFlags = number;
12564
+ type GPUSignedOffset32 = number;
12454
12565
  type GPUSize32 = number;
12455
12566
  type GPUSize32Out = number;
12456
12567
  type GPUSize64 = number;
12457
12568
  type GPUSize64Out = number;
12569
+ type GPUStencilValue = number;
12458
12570
  type GPUTextureUsageFlags = number;
12459
12571
  type HashAlgorithmIdentifier = AlgorithmIdentifier;
12460
12572
  type HeadersInit = [string, string][] | Record<string, string> | Headers;
@@ -12507,6 +12619,7 @@ type FrameType = "auxiliary" | "nested" | "none" | "top-level";
12507
12619
  type GPUBufferMapState = "mapped" | "pending" | "unmapped";
12508
12620
  type GPUCompilationMessageType = "error" | "info" | "warning";
12509
12621
  type GPUDeviceLostReason = "destroyed" | "unknown";
12622
+ type GPUIndexFormat = "uint16" | "uint32";
12510
12623
  type GPUPipelineErrorReason = "internal" | "validation";
12511
12624
  type GPUQueryType = "occlusion" | "timestamp";
12512
12625
  type GPUTextureAspect = "all" | "depth-only" | "stencil-only";
@@ -12649,6 +12762,21 @@ interface GPUBindingCommandsMixin {
12649
12762
  setBindGroup(index: GPUIndex32, bindGroup: GPUBindGroup | null, dynamicOffsets?: GPUBufferDynamicOffset[]): void;
12650
12763
  }
12651
12764
 
12765
+ interface GPURenderPassEncoder {
12766
+ /**
12767
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
12768
+ *
12769
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
12770
+ */
12771
+ executeBundles(bundles: GPURenderBundle[]): void;
12772
+ /**
12773
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
12774
+ *
12775
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
12776
+ */
12777
+ setBlendConstant(color: number[]): void;
12778
+ }
12779
+
12652
12780
  interface GPUSupportedFeatures extends ReadonlySet<string> {
12653
12781
  }
12654
12782
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@types/serviceworker",
3
- "version": "0.0.179",
3
+ "version": "0.0.181",
4
4
  "description": "Types for the global scope of Service Workers",
5
5
  "license": "Apache-2.0",
6
6
  "contributors": [],
package/ts5.5/index.d.ts CHANGED
@@ -272,6 +272,13 @@ interface FontFaceSetLoadEventInit extends EventInit {
272
272
  fontfaces?: FontFace[];
273
273
  }
274
274
 
275
+ interface GPUColorDict {
276
+ a: number;
277
+ b: number;
278
+ g: number;
279
+ r: number;
280
+ }
281
+
275
282
  interface GPUObjectDescriptorBase {
276
283
  label?: string;
277
284
  }
@@ -280,6 +287,9 @@ interface GPUPipelineErrorInit {
280
287
  reason: GPUPipelineErrorReason;
281
288
  }
282
289
 
290
+ interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
291
+ }
292
+
283
293
  interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
284
294
  arrayLayerCount?: GPUIntegerCoordinate;
285
295
  aspect?: GPUTextureAspect;
@@ -4610,6 +4620,105 @@ declare var GPURenderBundle: {
4610
4620
  new(): GPURenderBundle;
4611
4621
  };
4612
4622
 
4623
+ /**
4624
+ * The **`GPURenderBundleEncoder`** interface of the WebGPU API is used to pre-record bundles of commands.
4625
+ * Available only in secure contexts.
4626
+ *
4627
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder)
4628
+ */
4629
+ interface GPURenderBundleEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4630
+ /**
4631
+ * The **`finish()`** method of the GPURenderBundleEncoder interface completes recording of the current render bundle command sequence, returning a GPURenderBundle object that can be passed into a GPURenderPassEncoder.executeBundles() call to execute those commands in a specific render pass.
4632
+ *
4633
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/finish)
4634
+ */
4635
+ finish(descriptor?: GPURenderBundleDescriptor): GPURenderBundle;
4636
+ }
4637
+
4638
+ declare var GPURenderBundleEncoder: {
4639
+ prototype: GPURenderBundleEncoder;
4640
+ new(): GPURenderBundleEncoder;
4641
+ };
4642
+
4643
+ interface GPURenderCommandsMixin {
4644
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/draw) */
4645
+ draw(vertexCount: GPUSize32, instanceCount?: GPUSize32, firstVertex?: GPUSize32, firstInstance?: GPUSize32): void;
4646
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexed) */
4647
+ drawIndexed(indexCount: GPUSize32, instanceCount?: GPUSize32, firstIndex?: GPUSize32, baseVertex?: GPUSignedOffset32, firstInstance?: GPUSize32): void;
4648
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexedIndirect) */
4649
+ drawIndexedIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4650
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndirect) */
4651
+ drawIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4652
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setIndexBuffer) */
4653
+ setIndexBuffer(buffer: GPUBuffer, indexFormat: GPUIndexFormat, offset?: GPUSize64, size?: GPUSize64): void;
4654
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setPipeline) */
4655
+ setPipeline(pipeline: GPURenderPipeline): void;
4656
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setVertexBuffer) */
4657
+ setVertexBuffer(slot: GPUIndex32, buffer: GPUBuffer | null, offset?: GPUSize64, size?: GPUSize64): void;
4658
+ }
4659
+
4660
+ /**
4661
+ * The **`GPURenderPassEncoder`** interface of the WebGPU API encodes commands related to controlling the vertex and fragment shader stages, as issued by a GPURenderPipeline. It forms part of the overall encoding activity of a GPUCommandEncoder.
4662
+ * Available only in secure contexts.
4663
+ *
4664
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder)
4665
+ */
4666
+ interface GPURenderPassEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4667
+ /**
4668
+ * The **`beginOcclusionQuery()`** method of the GPURenderPassEncoder interface begins an occlusion query at the specified index of the relevant GPUQuerySet (provided as the value of the occlusionQuerySet descriptor property when invoking GPUCommandEncoder.beginRenderPass() to run the render pass).
4669
+ *
4670
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/beginOcclusionQuery)
4671
+ */
4672
+ beginOcclusionQuery(queryIndex: GPUSize32): void;
4673
+ /**
4674
+ * The **`end()`** method of the GPURenderPassEncoder interface completes recording of the current render pass command sequence.
4675
+ *
4676
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/end)
4677
+ */
4678
+ end(): void;
4679
+ /**
4680
+ * The **`endOcclusionQuery()`** method of the GPURenderPassEncoder interface ends an active occlusion query previously started with beginOcclusionQuery().
4681
+ *
4682
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/endOcclusionQuery)
4683
+ */
4684
+ endOcclusionQuery(): void;
4685
+ /**
4686
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
4687
+ *
4688
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
4689
+ */
4690
+ executeBundles(bundles: GPURenderBundle[]): void;
4691
+ /**
4692
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
4693
+ *
4694
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
4695
+ */
4696
+ setBlendConstant(color: GPUColor): void;
4697
+ /**
4698
+ * The **`setScissorRect()`** method of the GPURenderPassEncoder interface sets the scissor rectangle used during the rasterization stage. After transformation into viewport coordinates any fragments that fall outside the scissor rectangle will be discarded.
4699
+ *
4700
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setScissorRect)
4701
+ */
4702
+ setScissorRect(x: GPUIntegerCoordinate, y: GPUIntegerCoordinate, width: GPUIntegerCoordinate, height: GPUIntegerCoordinate): void;
4703
+ /**
4704
+ * The **`setStencilReference()`** method of the GPURenderPassEncoder interface sets the stencil reference value using during stencil tests with the "replace" stencil operation (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the properties defining the various stencil operations).
4705
+ *
4706
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setStencilReference)
4707
+ */
4708
+ setStencilReference(reference: GPUStencilValue): void;
4709
+ /**
4710
+ * The **`setViewport()`** method of the GPURenderPassEncoder interface sets the viewport used during the rasterization stage to linearly map from normalized device coordinates to viewport coordinates.
4711
+ *
4712
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setViewport)
4713
+ */
4714
+ setViewport(x: number, y: number, width: number, height: number, minDepth: number, maxDepth: number): void;
4715
+ }
4716
+
4717
+ declare var GPURenderPassEncoder: {
4718
+ prototype: GPURenderPassEncoder;
4719
+ new(): GPURenderPassEncoder;
4720
+ };
4721
+
4613
4722
  /**
4614
4723
  * The **`GPURenderPipeline`** interface of the WebGPU API represents a pipeline that controls the vertex and fragment shader stages and can be used in a GPURenderPassEncoder or GPURenderBundleEncoder.
4615
4724
  * Available only in secure contexts.
@@ -11551,7 +11660,7 @@ interface WorkerGlobalScope extends EventTarget, FontFaceSource, WindowOrWorkerG
11551
11660
  */
11552
11661
  readonly self: WorkerGlobalScope & typeof globalThis;
11553
11662
  /**
11554
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
11663
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
11555
11664
  *
11556
11665
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
11557
11666
  */
@@ -12352,7 +12461,7 @@ declare var onunhandledrejection: ((this: ServiceWorkerGlobalScope, ev: PromiseR
12352
12461
  */
12353
12462
  declare var self: WorkerGlobalScope & typeof globalThis;
12354
12463
  /**
12355
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
12464
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
12356
12465
  *
12357
12466
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
12358
12467
  */
@@ -12443,15 +12552,18 @@ type GLsizeiptr = number;
12443
12552
  type GLuint = number;
12444
12553
  type GLuint64 = number;
12445
12554
  type GPUBufferDynamicOffset = number;
12555
+ type GPUColor = number[] | GPUColorDict;
12446
12556
  type GPUFlagsConstant = number;
12447
12557
  type GPUIndex32 = number;
12448
12558
  type GPUIntegerCoordinate = number;
12449
12559
  type GPUIntegerCoordinateOut = number;
12450
12560
  type GPUMapModeFlags = number;
12561
+ type GPUSignedOffset32 = number;
12451
12562
  type GPUSize32 = number;
12452
12563
  type GPUSize32Out = number;
12453
12564
  type GPUSize64 = number;
12454
12565
  type GPUSize64Out = number;
12566
+ type GPUStencilValue = number;
12455
12567
  type GPUTextureUsageFlags = number;
12456
12568
  type HashAlgorithmIdentifier = AlgorithmIdentifier;
12457
12569
  type HeadersInit = [string, string][] | Record<string, string> | Headers;
@@ -12504,6 +12616,7 @@ type FrameType = "auxiliary" | "nested" | "none" | "top-level";
12504
12616
  type GPUBufferMapState = "mapped" | "pending" | "unmapped";
12505
12617
  type GPUCompilationMessageType = "error" | "info" | "warning";
12506
12618
  type GPUDeviceLostReason = "destroyed" | "unknown";
12619
+ type GPUIndexFormat = "uint16" | "uint32";
12507
12620
  type GPUPipelineErrorReason = "internal" | "validation";
12508
12621
  type GPUQueryType = "occlusion" | "timestamp";
12509
12622
  type GPUTextureAspect = "all" | "depth-only" | "stencil-only";
@@ -83,6 +83,21 @@ interface GPUBindingCommandsMixin {
83
83
  setBindGroup(index: GPUIndex32, bindGroup: GPUBindGroup | null, dynamicOffsets?: Iterable<GPUBufferDynamicOffset>): void;
84
84
  }
85
85
 
86
+ interface GPURenderPassEncoder {
87
+ /**
88
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
89
+ *
90
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
91
+ */
92
+ executeBundles(bundles: Iterable<GPURenderBundle>): void;
93
+ /**
94
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
95
+ *
96
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
97
+ */
98
+ setBlendConstant(color: Iterable<number>): void;
99
+ }
100
+
86
101
  interface GPUSupportedFeatures extends ReadonlySet<string> {
87
102
  }
88
103
 
package/ts5.6/index.d.ts CHANGED
@@ -272,6 +272,13 @@ interface FontFaceSetLoadEventInit extends EventInit {
272
272
  fontfaces?: FontFace[];
273
273
  }
274
274
 
275
+ interface GPUColorDict {
276
+ a: number;
277
+ b: number;
278
+ g: number;
279
+ r: number;
280
+ }
281
+
275
282
  interface GPUObjectDescriptorBase {
276
283
  label?: string;
277
284
  }
@@ -280,6 +287,9 @@ interface GPUPipelineErrorInit {
280
287
  reason: GPUPipelineErrorReason;
281
288
  }
282
289
 
290
+ interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
291
+ }
292
+
283
293
  interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
284
294
  arrayLayerCount?: GPUIntegerCoordinate;
285
295
  aspect?: GPUTextureAspect;
@@ -4610,6 +4620,105 @@ declare var GPURenderBundle: {
4610
4620
  new(): GPURenderBundle;
4611
4621
  };
4612
4622
 
4623
+ /**
4624
+ * The **`GPURenderBundleEncoder`** interface of the WebGPU API is used to pre-record bundles of commands.
4625
+ * Available only in secure contexts.
4626
+ *
4627
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder)
4628
+ */
4629
+ interface GPURenderBundleEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4630
+ /**
4631
+ * The **`finish()`** method of the GPURenderBundleEncoder interface completes recording of the current render bundle command sequence, returning a GPURenderBundle object that can be passed into a GPURenderPassEncoder.executeBundles() call to execute those commands in a specific render pass.
4632
+ *
4633
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/finish)
4634
+ */
4635
+ finish(descriptor?: GPURenderBundleDescriptor): GPURenderBundle;
4636
+ }
4637
+
4638
+ declare var GPURenderBundleEncoder: {
4639
+ prototype: GPURenderBundleEncoder;
4640
+ new(): GPURenderBundleEncoder;
4641
+ };
4642
+
4643
+ interface GPURenderCommandsMixin {
4644
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/draw) */
4645
+ draw(vertexCount: GPUSize32, instanceCount?: GPUSize32, firstVertex?: GPUSize32, firstInstance?: GPUSize32): void;
4646
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexed) */
4647
+ drawIndexed(indexCount: GPUSize32, instanceCount?: GPUSize32, firstIndex?: GPUSize32, baseVertex?: GPUSignedOffset32, firstInstance?: GPUSize32): void;
4648
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexedIndirect) */
4649
+ drawIndexedIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4650
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndirect) */
4651
+ drawIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4652
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setIndexBuffer) */
4653
+ setIndexBuffer(buffer: GPUBuffer, indexFormat: GPUIndexFormat, offset?: GPUSize64, size?: GPUSize64): void;
4654
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setPipeline) */
4655
+ setPipeline(pipeline: GPURenderPipeline): void;
4656
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setVertexBuffer) */
4657
+ setVertexBuffer(slot: GPUIndex32, buffer: GPUBuffer | null, offset?: GPUSize64, size?: GPUSize64): void;
4658
+ }
4659
+
4660
+ /**
4661
+ * The **`GPURenderPassEncoder`** interface of the WebGPU API encodes commands related to controlling the vertex and fragment shader stages, as issued by a GPURenderPipeline. It forms part of the overall encoding activity of a GPUCommandEncoder.
4662
+ * Available only in secure contexts.
4663
+ *
4664
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder)
4665
+ */
4666
+ interface GPURenderPassEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4667
+ /**
4668
+ * The **`beginOcclusionQuery()`** method of the GPURenderPassEncoder interface begins an occlusion query at the specified index of the relevant GPUQuerySet (provided as the value of the occlusionQuerySet descriptor property when invoking GPUCommandEncoder.beginRenderPass() to run the render pass).
4669
+ *
4670
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/beginOcclusionQuery)
4671
+ */
4672
+ beginOcclusionQuery(queryIndex: GPUSize32): void;
4673
+ /**
4674
+ * The **`end()`** method of the GPURenderPassEncoder interface completes recording of the current render pass command sequence.
4675
+ *
4676
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/end)
4677
+ */
4678
+ end(): void;
4679
+ /**
4680
+ * The **`endOcclusionQuery()`** method of the GPURenderPassEncoder interface ends an active occlusion query previously started with beginOcclusionQuery().
4681
+ *
4682
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/endOcclusionQuery)
4683
+ */
4684
+ endOcclusionQuery(): void;
4685
+ /**
4686
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
4687
+ *
4688
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
4689
+ */
4690
+ executeBundles(bundles: GPURenderBundle[]): void;
4691
+ /**
4692
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
4693
+ *
4694
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
4695
+ */
4696
+ setBlendConstant(color: GPUColor): void;
4697
+ /**
4698
+ * The **`setScissorRect()`** method of the GPURenderPassEncoder interface sets the scissor rectangle used during the rasterization stage. After transformation into viewport coordinates any fragments that fall outside the scissor rectangle will be discarded.
4699
+ *
4700
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setScissorRect)
4701
+ */
4702
+ setScissorRect(x: GPUIntegerCoordinate, y: GPUIntegerCoordinate, width: GPUIntegerCoordinate, height: GPUIntegerCoordinate): void;
4703
+ /**
4704
+ * The **`setStencilReference()`** method of the GPURenderPassEncoder interface sets the stencil reference value using during stencil tests with the "replace" stencil operation (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the properties defining the various stencil operations).
4705
+ *
4706
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setStencilReference)
4707
+ */
4708
+ setStencilReference(reference: GPUStencilValue): void;
4709
+ /**
4710
+ * The **`setViewport()`** method of the GPURenderPassEncoder interface sets the viewport used during the rasterization stage to linearly map from normalized device coordinates to viewport coordinates.
4711
+ *
4712
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setViewport)
4713
+ */
4714
+ setViewport(x: number, y: number, width: number, height: number, minDepth: number, maxDepth: number): void;
4715
+ }
4716
+
4717
+ declare var GPURenderPassEncoder: {
4718
+ prototype: GPURenderPassEncoder;
4719
+ new(): GPURenderPassEncoder;
4720
+ };
4721
+
4613
4722
  /**
4614
4723
  * The **`GPURenderPipeline`** interface of the WebGPU API represents a pipeline that controls the vertex and fragment shader stages and can be used in a GPURenderPassEncoder or GPURenderBundleEncoder.
4615
4724
  * Available only in secure contexts.
@@ -11551,7 +11660,7 @@ interface WorkerGlobalScope extends EventTarget, FontFaceSource, WindowOrWorkerG
11551
11660
  */
11552
11661
  readonly self: WorkerGlobalScope & typeof globalThis;
11553
11662
  /**
11554
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
11663
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
11555
11664
  *
11556
11665
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
11557
11666
  */
@@ -12352,7 +12461,7 @@ declare var onunhandledrejection: ((this: ServiceWorkerGlobalScope, ev: PromiseR
12352
12461
  */
12353
12462
  declare var self: WorkerGlobalScope & typeof globalThis;
12354
12463
  /**
12355
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
12464
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
12356
12465
  *
12357
12466
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
12358
12467
  */
@@ -12443,15 +12552,18 @@ type GLsizeiptr = number;
12443
12552
  type GLuint = number;
12444
12553
  type GLuint64 = number;
12445
12554
  type GPUBufferDynamicOffset = number;
12555
+ type GPUColor = number[] | GPUColorDict;
12446
12556
  type GPUFlagsConstant = number;
12447
12557
  type GPUIndex32 = number;
12448
12558
  type GPUIntegerCoordinate = number;
12449
12559
  type GPUIntegerCoordinateOut = number;
12450
12560
  type GPUMapModeFlags = number;
12561
+ type GPUSignedOffset32 = number;
12451
12562
  type GPUSize32 = number;
12452
12563
  type GPUSize32Out = number;
12453
12564
  type GPUSize64 = number;
12454
12565
  type GPUSize64Out = number;
12566
+ type GPUStencilValue = number;
12455
12567
  type GPUTextureUsageFlags = number;
12456
12568
  type HashAlgorithmIdentifier = AlgorithmIdentifier;
12457
12569
  type HeadersInit = [string, string][] | Record<string, string> | Headers;
@@ -12504,6 +12616,7 @@ type FrameType = "auxiliary" | "nested" | "none" | "top-level";
12504
12616
  type GPUBufferMapState = "mapped" | "pending" | "unmapped";
12505
12617
  type GPUCompilationMessageType = "error" | "info" | "warning";
12506
12618
  type GPUDeviceLostReason = "destroyed" | "unknown";
12619
+ type GPUIndexFormat = "uint16" | "uint32";
12507
12620
  type GPUPipelineErrorReason = "internal" | "validation";
12508
12621
  type GPUQueryType = "occlusion" | "timestamp";
12509
12622
  type GPUTextureAspect = "all" | "depth-only" | "stencil-only";
@@ -87,6 +87,21 @@ interface GPUBindingCommandsMixin {
87
87
  setBindGroup(index: GPUIndex32, bindGroup: GPUBindGroup | null, dynamicOffsets?: Iterable<GPUBufferDynamicOffset>): void;
88
88
  }
89
89
 
90
+ interface GPURenderPassEncoder {
91
+ /**
92
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
93
+ *
94
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
95
+ */
96
+ executeBundles(bundles: Iterable<GPURenderBundle>): void;
97
+ /**
98
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
99
+ *
100
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
101
+ */
102
+ setBlendConstant(color: Iterable<number>): void;
103
+ }
104
+
90
105
  interface GPUSupportedFeatures extends ReadonlySet<string> {
91
106
  }
92
107
 
package/ts5.9/index.d.ts CHANGED
@@ -272,6 +272,13 @@ interface FontFaceSetLoadEventInit extends EventInit {
272
272
  fontfaces?: FontFace[];
273
273
  }
274
274
 
275
+ interface GPUColorDict {
276
+ a: number;
277
+ b: number;
278
+ g: number;
279
+ r: number;
280
+ }
281
+
275
282
  interface GPUObjectDescriptorBase {
276
283
  label?: string;
277
284
  }
@@ -280,6 +287,9 @@ interface GPUPipelineErrorInit {
280
287
  reason: GPUPipelineErrorReason;
281
288
  }
282
289
 
290
+ interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
291
+ }
292
+
283
293
  interface GPUTextureViewDescriptor extends GPUObjectDescriptorBase {
284
294
  arrayLayerCount?: GPUIntegerCoordinate;
285
295
  aspect?: GPUTextureAspect;
@@ -4610,6 +4620,105 @@ declare var GPURenderBundle: {
4610
4620
  new(): GPURenderBundle;
4611
4621
  };
4612
4622
 
4623
+ /**
4624
+ * The **`GPURenderBundleEncoder`** interface of the WebGPU API is used to pre-record bundles of commands.
4625
+ * Available only in secure contexts.
4626
+ *
4627
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder)
4628
+ */
4629
+ interface GPURenderBundleEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4630
+ /**
4631
+ * The **`finish()`** method of the GPURenderBundleEncoder interface completes recording of the current render bundle command sequence, returning a GPURenderBundle object that can be passed into a GPURenderPassEncoder.executeBundles() call to execute those commands in a specific render pass.
4632
+ *
4633
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/finish)
4634
+ */
4635
+ finish(descriptor?: GPURenderBundleDescriptor): GPURenderBundle;
4636
+ }
4637
+
4638
+ declare var GPURenderBundleEncoder: {
4639
+ prototype: GPURenderBundleEncoder;
4640
+ new(): GPURenderBundleEncoder;
4641
+ };
4642
+
4643
+ interface GPURenderCommandsMixin {
4644
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/draw) */
4645
+ draw(vertexCount: GPUSize32, instanceCount?: GPUSize32, firstVertex?: GPUSize32, firstInstance?: GPUSize32): void;
4646
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexed) */
4647
+ drawIndexed(indexCount: GPUSize32, instanceCount?: GPUSize32, firstIndex?: GPUSize32, baseVertex?: GPUSignedOffset32, firstInstance?: GPUSize32): void;
4648
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndexedIndirect) */
4649
+ drawIndexedIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4650
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/drawIndirect) */
4651
+ drawIndirect(indirectBuffer: GPUBuffer, indirectOffset: GPUSize64): void;
4652
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setIndexBuffer) */
4653
+ setIndexBuffer(buffer: GPUBuffer, indexFormat: GPUIndexFormat, offset?: GPUSize64, size?: GPUSize64): void;
4654
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setPipeline) */
4655
+ setPipeline(pipeline: GPURenderPipeline): void;
4656
+ /** [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderBundleEncoder/setVertexBuffer) */
4657
+ setVertexBuffer(slot: GPUIndex32, buffer: GPUBuffer | null, offset?: GPUSize64, size?: GPUSize64): void;
4658
+ }
4659
+
4660
+ /**
4661
+ * The **`GPURenderPassEncoder`** interface of the WebGPU API encodes commands related to controlling the vertex and fragment shader stages, as issued by a GPURenderPipeline. It forms part of the overall encoding activity of a GPUCommandEncoder.
4662
+ * Available only in secure contexts.
4663
+ *
4664
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder)
4665
+ */
4666
+ interface GPURenderPassEncoder extends GPUBindingCommandsMixin, GPUDebugCommandsMixin, GPUObjectBase, GPURenderCommandsMixin {
4667
+ /**
4668
+ * The **`beginOcclusionQuery()`** method of the GPURenderPassEncoder interface begins an occlusion query at the specified index of the relevant GPUQuerySet (provided as the value of the occlusionQuerySet descriptor property when invoking GPUCommandEncoder.beginRenderPass() to run the render pass).
4669
+ *
4670
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/beginOcclusionQuery)
4671
+ */
4672
+ beginOcclusionQuery(queryIndex: GPUSize32): void;
4673
+ /**
4674
+ * The **`end()`** method of the GPURenderPassEncoder interface completes recording of the current render pass command sequence.
4675
+ *
4676
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/end)
4677
+ */
4678
+ end(): void;
4679
+ /**
4680
+ * The **`endOcclusionQuery()`** method of the GPURenderPassEncoder interface ends an active occlusion query previously started with beginOcclusionQuery().
4681
+ *
4682
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/endOcclusionQuery)
4683
+ */
4684
+ endOcclusionQuery(): void;
4685
+ /**
4686
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
4687
+ *
4688
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
4689
+ */
4690
+ executeBundles(bundles: GPURenderBundle[]): void;
4691
+ /**
4692
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
4693
+ *
4694
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
4695
+ */
4696
+ setBlendConstant(color: GPUColor): void;
4697
+ /**
4698
+ * The **`setScissorRect()`** method of the GPURenderPassEncoder interface sets the scissor rectangle used during the rasterization stage. After transformation into viewport coordinates any fragments that fall outside the scissor rectangle will be discarded.
4699
+ *
4700
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setScissorRect)
4701
+ */
4702
+ setScissorRect(x: GPUIntegerCoordinate, y: GPUIntegerCoordinate, width: GPUIntegerCoordinate, height: GPUIntegerCoordinate): void;
4703
+ /**
4704
+ * The **`setStencilReference()`** method of the GPURenderPassEncoder interface sets the stencil reference value using during stencil tests with the "replace" stencil operation (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the properties defining the various stencil operations).
4705
+ *
4706
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setStencilReference)
4707
+ */
4708
+ setStencilReference(reference: GPUStencilValue): void;
4709
+ /**
4710
+ * The **`setViewport()`** method of the GPURenderPassEncoder interface sets the viewport used during the rasterization stage to linearly map from normalized device coordinates to viewport coordinates.
4711
+ *
4712
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setViewport)
4713
+ */
4714
+ setViewport(x: number, y: number, width: number, height: number, minDepth: number, maxDepth: number): void;
4715
+ }
4716
+
4717
+ declare var GPURenderPassEncoder: {
4718
+ prototype: GPURenderPassEncoder;
4719
+ new(): GPURenderPassEncoder;
4720
+ };
4721
+
4613
4722
  /**
4614
4723
  * The **`GPURenderPipeline`** interface of the WebGPU API represents a pipeline that controls the vertex and fragment shader stages and can be used in a GPURenderPassEncoder or GPURenderBundleEncoder.
4615
4724
  * Available only in secure contexts.
@@ -11551,7 +11660,7 @@ interface WorkerGlobalScope extends EventTarget, FontFaceSource, WindowOrWorkerG
11551
11660
  */
11552
11661
  readonly self: WorkerGlobalScope & typeof globalThis;
11553
11662
  /**
11554
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
11663
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
11555
11664
  *
11556
11665
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
11557
11666
  */
@@ -12352,7 +12461,7 @@ declare var onunhandledrejection: ((this: ServiceWorkerGlobalScope, ev: PromiseR
12352
12461
  */
12353
12462
  declare var self: WorkerGlobalScope & typeof globalThis;
12354
12463
  /**
12355
- * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the worker's scope.
12464
+ * The **`importScripts()`** method of the WorkerGlobalScope interface synchronously imports one or more scripts into the scope of a classic worker (a worker constructed from a classic script).
12356
12465
  *
12357
12466
  * [MDN Reference](https://developer.mozilla.org/docs/Web/API/WorkerGlobalScope/importScripts)
12358
12467
  */
@@ -12443,15 +12552,18 @@ type GLsizeiptr = number;
12443
12552
  type GLuint = number;
12444
12553
  type GLuint64 = number;
12445
12554
  type GPUBufferDynamicOffset = number;
12555
+ type GPUColor = number[] | GPUColorDict;
12446
12556
  type GPUFlagsConstant = number;
12447
12557
  type GPUIndex32 = number;
12448
12558
  type GPUIntegerCoordinate = number;
12449
12559
  type GPUIntegerCoordinateOut = number;
12450
12560
  type GPUMapModeFlags = number;
12561
+ type GPUSignedOffset32 = number;
12451
12562
  type GPUSize32 = number;
12452
12563
  type GPUSize32Out = number;
12453
12564
  type GPUSize64 = number;
12454
12565
  type GPUSize64Out = number;
12566
+ type GPUStencilValue = number;
12455
12567
  type GPUTextureUsageFlags = number;
12456
12568
  type HashAlgorithmIdentifier = AlgorithmIdentifier;
12457
12569
  type HeadersInit = [string, string][] | Record<string, string> | Headers;
@@ -12504,6 +12616,7 @@ type FrameType = "auxiliary" | "nested" | "none" | "top-level";
12504
12616
  type GPUBufferMapState = "mapped" | "pending" | "unmapped";
12505
12617
  type GPUCompilationMessageType = "error" | "info" | "warning";
12506
12618
  type GPUDeviceLostReason = "destroyed" | "unknown";
12619
+ type GPUIndexFormat = "uint16" | "uint32";
12507
12620
  type GPUPipelineErrorReason = "internal" | "validation";
12508
12621
  type GPUQueryType = "occlusion" | "timestamp";
12509
12622
  type GPUTextureAspect = "all" | "depth-only" | "stencil-only";
@@ -87,6 +87,21 @@ interface GPUBindingCommandsMixin {
87
87
  setBindGroup(index: GPUIndex32, bindGroup: GPUBindGroup | null, dynamicOffsets?: Iterable<GPUBufferDynamicOffset>): void;
88
88
  }
89
89
 
90
+ interface GPURenderPassEncoder {
91
+ /**
92
+ * The **`executeBundles()`** method of the GPURenderPassEncoder interface executes commands previously recorded into the referenced GPURenderBundles, as part of this render pass.
93
+ *
94
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/executeBundles)
95
+ */
96
+ executeBundles(bundles: Iterable<GPURenderBundle>): void;
97
+ /**
98
+ * The **`setBlendConstant()`** method of the GPURenderPassEncoder interface sets the constant blend color and alpha values used with "constant" and "one-minus-constant" blend factors (as set in the descriptor of the GPUDevice.createRenderPipeline() method, in the blend property).
99
+ *
100
+ * [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPURenderPassEncoder/setBlendConstant)
101
+ */
102
+ setBlendConstant(color: Iterable<number>): void;
103
+ }
104
+
90
105
  interface GPUSupportedFeatures extends ReadonlySet<string> {
91
106
  }
92
107