Metal: Pass fixed sample mask to MSL transform

Tint now combines a fixed sample mask with any mask authored in the
shader, and generates the builtin if necessary.

Fixed: tint:387
Change-Id: Ic084f28356432566e8d2566f45cf0730f4cd2f6d
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/55686
Auto-Submit: James Price <jrprice@google.com>
Commit-Queue: Austin Eng <enga@chromium.org>
Reviewed-by: Austin Eng <enga@chromium.org>
This commit is contained in:
James Price 2021-06-23 03:01:09 +00:00 committed by Dawn LUCI CQ
parent 59dffe0a9b
commit a7173fcab4
1 changed files with 1 additions and 2 deletions

View File

@ -55,7 +55,6 @@ namespace dawn_native { namespace metal {
const char* entryPointName,
SingleShaderStage stage,
const PipelineLayout* layout,
// TODO(crbug.com/tint/387): AND in a fixed sample mask in the shader.
uint32_t sampleMask,
const RenderPipeline* renderPipeline,
const VertexState* vertexState,
@ -130,7 +129,7 @@ namespace dawn_native { namespace metal {
std::move(accessControls),
/* mayCollide */ true);
transformInputs.Add<tint::transform::Msl::Config>(kBufferLengthBufferSlot);
transformInputs.Add<tint::transform::Msl::Config>(kBufferLengthBufferSlot, sampleMask);
tint::Program program;
tint::transform::DataMap transformOutputs;