Skip to content

Commit 6d24700

Browse files
authored
Add immediates related changes in types (#195)
Immediates PR: gpuweb/gpuweb#5423
1 parent 645c8d5 commit 6d24700

1 file changed

Lines changed: 22 additions & 0 deletions

File tree

dist/index.d.ts

Lines changed: 22 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1098,6 +1098,11 @@ interface GPUPipelineLayoutDescriptor
10981098
| null
10991099
| undefined
11001100
>;
1101+
1102+
/**
1103+
* The size in bytes of the immediate data range.
1104+
*/
1105+
immediateSize?: GPUSize32;
11011106
}
11021107

11031108
interface GPUPrimitiveState {
@@ -1924,6 +1929,21 @@ interface GPUBindingCommandsMixin {
19241929
dynamicOffsetsDataStart: GPUSize64,
19251930
dynamicOffsetsDataLength: GPUSize32
19261931
): undefined;
1932+
/**
1933+
* Sets immediate data for subsequent render or compute commands
1934+
* @param rangeOffset - Offset in bytes into the immediate data range to begin writing at.
1935+
* @param data - Data to write into the immediate data range.
1936+
* @param dataOffset - Offset into `data` to begin writing from. Given in elements if
1937+
* `data` is a `TypedArray` and bytes otherwise. Defaults to 0.
1938+
* @param size - Size of content to write from `data` to `buffer`. Given in elements if
1939+
* `data` is a `TypedArray` and bytes otherwise.
1940+
*/
1941+
setImmediates(
1942+
rangeOffset: GPUSize32,
1943+
data: GPUAllowSharedBufferSource,
1944+
dataOffset?: GPUSize64,
1945+
size?: GPUSize64
1946+
): undefined;
19271947
}
19281948

19291949
interface GPUCommandsMixin {}
@@ -3174,6 +3194,8 @@ interface GPUSupportedLimits {
31743194
readonly maxComputeWorkgroupSizeY: number;
31753195
readonly maxComputeWorkgroupSizeZ: number;
31763196
readonly maxComputeWorkgroupsPerDimension: number;
3197+
/** **PROPOSED** in [Immediates](https://github.com/gpuweb/gpuweb/pull/5423). */
3198+
readonly maxImmediateSize: number;
31773199
/** **PROPOSED** in [Compatibility Mode](https://github.com/gpuweb/gpuweb/blob/main/proposals/compatibility-mode.md). */
31783200
readonly maxStorageBuffersInVertexStage?: number;
31793201
/** **PROPOSED** in [Compatibility Mode](https://github.com/gpuweb/gpuweb/blob/main/proposals/compatibility-mode.md). */

0 commit comments

Comments
 (0)