Skip to content

Commit 096e02e

Browse files
authored
Add GPUDevice.createPipelineLayout/QuerySet (#2415)
Co-authored-by: saschanaz <saschanaz@users.noreply.github.com>
1 parent 4599f54 commit 096e02e

17 files changed

+336
-2
lines changed

baselines/dom.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -913,12 +913,21 @@ interface GPUPipelineErrorInit {
913913
reason: GPUPipelineErrorReason;
914914
}
915915

916+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
917+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
918+
}
919+
916920
interface GPUProgrammableStage {
917921
constants?: Record<string, GPUPipelineConstantValue>;
918922
entryPoint?: string;
919923
module: GPUShaderModule;
920924
}
921925

926+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
927+
count: GPUSize32;
928+
type: GPUQueryType;
929+
}
930+
922931
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
923932
}
924933

@@ -15403,6 +15412,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
1540315412
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
1540415413
*/
1540515414
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
15415+
/**
15416+
* 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.
15417+
*
15418+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
15419+
*/
15420+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
15421+
/**
15422+
* 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.
15423+
*
15424+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
15425+
*/
15426+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
1540615427
/**
1540715428
* 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.
1540815429
*

baselines/serviceworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -379,12 +379,21 @@ interface GPUPipelineErrorInit {
379379
reason: GPUPipelineErrorReason;
380380
}
381381

382+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
383+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
384+
}
385+
382386
interface GPUProgrammableStage {
383387
constants?: Record<string, GPUPipelineConstantValue>;
384388
entryPoint?: string;
385389
module: GPUShaderModule;
386390
}
387391

392+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
393+
count: GPUSize32;
394+
type: GPUQueryType;
395+
}
396+
388397
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
389398
}
390399

@@ -4845,6 +4854,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
48454854
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
48464855
*/
48474856
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
4857+
/**
4858+
* 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.
4859+
*
4860+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
4861+
*/
4862+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
4863+
/**
4864+
* 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.
4865+
*
4866+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
4867+
*/
4868+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
48484869
/**
48494870
* 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.
48504871
*

baselines/sharedworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -323,12 +323,21 @@ interface GPUPipelineErrorInit {
323323
reason: GPUPipelineErrorReason;
324324
}
325325

326+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
327+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
328+
}
329+
326330
interface GPUProgrammableStage {
327331
constants?: Record<string, GPUPipelineConstantValue>;
328332
entryPoint?: string;
329333
module: GPUShaderModule;
330334
}
331335

336+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
337+
count: GPUSize32;
338+
type: GPUQueryType;
339+
}
340+
332341
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
333342
}
334343

@@ -4528,6 +4537,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
45284537
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
45294538
*/
45304539
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
4540+
/**
4541+
* 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.
4542+
*
4543+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
4544+
*/
4545+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
4546+
/**
4547+
* 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.
4548+
*
4549+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
4550+
*/
4551+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
45314552
/**
45324553
* 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.
45334554
*

baselines/ts5.5/dom.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -910,12 +910,21 @@ interface GPUPipelineErrorInit {
910910
reason: GPUPipelineErrorReason;
911911
}
912912

913+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
914+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
915+
}
916+
913917
interface GPUProgrammableStage {
914918
constants?: Record<string, GPUPipelineConstantValue>;
915919
entryPoint?: string;
916920
module: GPUShaderModule;
917921
}
918922

923+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
924+
count: GPUSize32;
925+
type: GPUQueryType;
926+
}
927+
919928
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
920929
}
921930

@@ -15389,6 +15398,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
1538915398
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
1539015399
*/
1539115400
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
15401+
/**
15402+
* 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.
15403+
*
15404+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
15405+
*/
15406+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
15407+
/**
15408+
* 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.
15409+
*
15410+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
15411+
*/
15412+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
1539215413
/**
1539315414
* 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.
1539415415
*

baselines/ts5.5/serviceworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -376,12 +376,21 @@ interface GPUPipelineErrorInit {
376376
reason: GPUPipelineErrorReason;
377377
}
378378

379+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
380+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
381+
}
382+
379383
interface GPUProgrammableStage {
380384
constants?: Record<string, GPUPipelineConstantValue>;
381385
entryPoint?: string;
382386
module: GPUShaderModule;
383387
}
384388

389+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
390+
count: GPUSize32;
391+
type: GPUQueryType;
392+
}
393+
385394
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
386395
}
387396

@@ -4842,6 +4851,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
48424851
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
48434852
*/
48444853
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
4854+
/**
4855+
* 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.
4856+
*
4857+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
4858+
*/
4859+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
4860+
/**
4861+
* 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.
4862+
*
4863+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
4864+
*/
4865+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
48454866
/**
48464867
* 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.
48474868
*

baselines/ts5.5/sharedworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -320,12 +320,21 @@ interface GPUPipelineErrorInit {
320320
reason: GPUPipelineErrorReason;
321321
}
322322

323+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
324+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
325+
}
326+
323327
interface GPUProgrammableStage {
324328
constants?: Record<string, GPUPipelineConstantValue>;
325329
entryPoint?: string;
326330
module: GPUShaderModule;
327331
}
328332

333+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
334+
count: GPUSize32;
335+
type: GPUQueryType;
336+
}
337+
329338
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
330339
}
331340

@@ -4525,6 +4534,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
45254534
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
45264535
*/
45274536
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
4537+
/**
4538+
* 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.
4539+
*
4540+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
4541+
*/
4542+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
4543+
/**
4544+
* 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.
4545+
*
4546+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
4547+
*/
4548+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
45284549
/**
45294550
* 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.
45304551
*

baselines/ts5.5/webworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -467,12 +467,21 @@ interface GPUPipelineErrorInit {
467467
reason: GPUPipelineErrorReason;
468468
}
469469

470+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
471+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
472+
}
473+
470474
interface GPUProgrammableStage {
471475
constants?: Record<string, GPUPipelineConstantValue>;
472476
entryPoint?: string;
473477
module: GPUShaderModule;
474478
}
475479

480+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
481+
count: GPUSize32;
482+
type: GPUQueryType;
483+
}
484+
476485
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
477486
}
478487

@@ -5545,6 +5554,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
55455554
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
55465555
*/
55475556
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
5557+
/**
5558+
* 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.
5559+
*
5560+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
5561+
*/
5562+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
5563+
/**
5564+
* 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.
5565+
*
5566+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
5567+
*/
5568+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
55485569
/**
55495570
* 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.
55505571
*

baselines/ts5.6/dom.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -910,12 +910,21 @@ interface GPUPipelineErrorInit {
910910
reason: GPUPipelineErrorReason;
911911
}
912912

913+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
914+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
915+
}
916+
913917
interface GPUProgrammableStage {
914918
constants?: Record<string, GPUPipelineConstantValue>;
915919
entryPoint?: string;
916920
module: GPUShaderModule;
917921
}
918922

923+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
924+
count: GPUSize32;
925+
type: GPUQueryType;
926+
}
927+
919928
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
920929
}
921930

@@ -15400,6 +15409,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
1540015409
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
1540115410
*/
1540215411
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
15412+
/**
15413+
* 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.
15414+
*
15415+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
15416+
*/
15417+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
15418+
/**
15419+
* 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.
15420+
*
15421+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
15422+
*/
15423+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
1540315424
/**
1540415425
* 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.
1540515426
*

baselines/ts5.6/serviceworker.generated.d.ts

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -376,12 +376,21 @@ interface GPUPipelineErrorInit {
376376
reason: GPUPipelineErrorReason;
377377
}
378378

379+
interface GPUPipelineLayoutDescriptor extends GPUObjectDescriptorBase {
380+
bindGroupLayouts: (GPUBindGroupLayout | null)[];
381+
}
382+
379383
interface GPUProgrammableStage {
380384
constants?: Record<string, GPUPipelineConstantValue>;
381385
entryPoint?: string;
382386
module: GPUShaderModule;
383387
}
384388

389+
interface GPUQuerySetDescriptor extends GPUObjectDescriptorBase {
390+
count: GPUSize32;
391+
type: GPUQueryType;
392+
}
393+
385394
interface GPURenderBundleDescriptor extends GPUObjectDescriptorBase {
386395
}
387396

@@ -4842,6 +4851,18 @@ interface GPUDevice extends EventTarget, GPUObjectBase {
48424851
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createComputePipelineAsync)
48434852
*/
48444853
createComputePipelineAsync(descriptor: GPUComputePipelineDescriptor): Promise<GPUComputePipeline>;
4854+
/**
4855+
* 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.
4856+
*
4857+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createPipelineLayout)
4858+
*/
4859+
createPipelineLayout(descriptor: GPUPipelineLayoutDescriptor): GPUPipelineLayout;
4860+
/**
4861+
* 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.
4862+
*
4863+
* [MDN Reference](https://developer.mozilla.org/docs/Web/API/GPUDevice/createQuerySet)
4864+
*/
4865+
createQuerySet(descriptor: GPUQuerySetDescriptor): GPUQuerySet;
48454866
/**
48464867
* 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.
48474868
*

0 commit comments

Comments
 (0)