mirror of
https://github.com/encounter/dawn-cmake.git
synced 2025-12-17 17:05:31 +00:00
Implement sampleMask in D3D12 and OpenGL.
Some tests are not enabled in D3D12 yet because SPIRV-Cross lacks support for gl_SampleMask. Bug: dawn:491 Change-Id: I6cce56b5d0ab883f39b8d58987246c08a23b6410 Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/25580 Reviewed-by: Tomek Ponitka <tommek@google.com> Reviewed-by: Austin Eng <enga@chromium.org> Commit-Queue: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
committed by
Commit Bot service account
parent
4d9cadd58a
commit
c7ae7a0012
@@ -162,6 +162,7 @@ namespace dawn_native { namespace opengl {
|
||||
mFunctions.Enable(GL_PRIMITIVE_RESTART_FIXED_INDEX);
|
||||
mFunctions.Enable(GL_MULTISAMPLE);
|
||||
mFunctions.Enable(GL_FRAMEBUFFER_SRGB);
|
||||
mFunctions.Enable(GL_SAMPLE_MASK);
|
||||
|
||||
mPCIInfo.name = reinterpret_cast<const char*>(mFunctions.GetString(GL_RENDERER));
|
||||
|
||||
|
||||
@@ -257,6 +257,8 @@ namespace dawn_native { namespace opengl {
|
||||
|
||||
ApplyDepthStencilState(gl, GetDepthStencilStateDescriptor(), &persistentPipelineState);
|
||||
|
||||
gl.SampleMaski(0, GetSampleMask());
|
||||
|
||||
for (uint32_t attachmentSlot : IterateBitSet(GetColorAttachmentsMask())) {
|
||||
ApplyColorState(gl, attachmentSlot, GetColorStateDescriptor(attachmentSlot));
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user