Skip to content
Draft
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
23 changes: 23 additions & 0 deletions spec/index.bs
Original file line number Diff line number Diff line change
Expand Up @@ -1128,6 +1128,8 @@ dictionary GPULimits {
GPUSize32 maxStorageTexturesPerShaderStage = 4;
GPUSize32 maxUniformBuffersPerShaderStage = 12;
GPUSize32 maxUniformBufferBindingSize = 16384;
GPUSize64 sampleCountMask = 5;
GPUSize64 maxTexelBlockSize = 64;
};
</script>

Expand Down Expand Up @@ -1234,6 +1236,25 @@ dictionary GPULimits {
::
The maximum {{GPUBufferBinding}}.{{GPUBufferBinding/size}} for bindings of type {{GPUBindingType/uniform-buffer}}.

Higher is [=better=].

: <dfn>sampleCountMask</dfn>
::
The mask of supported values for {{GPUTextureDescriptor/sampleCount}},
{{GPURenderPipelineDescriptor/sampleCount}}, and {{GPURenderBundleEncoderDescriptor/sampleCount}}.

In each of these uses, the sample count is a power of two, and the relevant bit needs to be
included in this mask for valid usage.

The default limit supports MSAA levels of 4 and 1 (non-multisampled), resulting in the mask value of 5.

One mask is [=better=] than the other if it fully includes it.
: <dfn>maxTexelBlockSize</dfn>
::
Maximum size of a texel block that a texture can have.
In a multi-sampled texture, the texel block size is
the size of a format &times; the number of samples.

Higher is [=better=].
</dl>

Expand Down Expand Up @@ -1840,6 +1861,7 @@ interface GPUTextureUsage {
**Returns:** {{GPUTexture}}

Issue: Describe {{GPUDevice/createTexture()}} algorithm steps.
Issue: Take the `sampleCountMask` and `maxTexelBlockSize` into account.
</div>
</dl>

Expand Down Expand Up @@ -3538,6 +3560,7 @@ Issue: link to the semantics of SV_SampleIndex and SV_Coverage in WGSL spec.
|descriptor|.{{GPUPipelineDescriptorBase/layout}}) succeeds.
- |descriptor|.{{GPURenderPipelineDescriptor/colorStates}}.length is less than
or equal to 4.
- |descriptor|.{{GPURenderPipelineDescriptor/sampleCount}} is not included in {{GPULimits/sampleCountMask|GPULimits.sampleCountMask}}.
- [$validating GPUVertexStateDescriptor$](|descriptor|.{{GPURenderPipelineDescriptor/vertexState}},
|descriptor|.{{GPURenderPipelineDescriptor/vertexStage}}) passes.
- If |descriptor|.{{GPURenderPipelineDescriptor/alphaToCoverageEnabled}} is `true`:
Expand Down