Implement a toggle to disable sample variables.

Sample mask variables and all functionality introduced by GL_OES_sample_variables was not made core until ES 3.2.

Implement a toggle to disable the functionality if not supported by the backend.

Bug: dawn:673
Change-Id: I7a5ec61fb57da343f0f72ffd3b0c69031eaaff8f
Reviewed-on: https://dawn-review.googlesource.com/c/dawn/+/41142
Commit-Queue: Stephen White <senorblanco@chromium.org>
Reviewed-by: Corentin Wallez <cwallez@chromium.org>
This commit is contained in:
Stephen White
2021-02-10 02:28:17 +00:00
committed by Commit Bot service account
parent 39b478df0c
commit 02fd17c754
4 changed files with 16 additions and 4 deletions

View File

@@ -736,8 +736,9 @@ TEST_P(MultisampledRenderingTest, ResolveInto2DTextureWithSampleMaskAndShaderOut
// TODO(crbug.com/tint/372): Support sample mask builtin.
DAWN_SKIP_TEST_IF(HasToggleEnabled("use_tint_generator"));
// TODO(crbug.com/dawn/644): Diagnose and fix this ANGLE failure.
DAWN_SKIP_TEST_IF(IsANGLE());
// TODO(crbug.com/dawn/672): Work around or enforce via validation that sample variables are not
// supported on some platforms.
DAWN_SKIP_TEST_IF(HasToggleEnabled("disable_sample_variables"));
constexpr bool kTestDepth = false;
wgpu::CommandEncoder commandEncoder = device.CreateCommandEncoder();
@@ -785,8 +786,9 @@ TEST_P(MultisampledRenderingTest, ResolveIntoMultipleResolveTargetsWithShaderOut
// TODO(crbug.com/tint/372): Support sample mask builtin.
DAWN_SKIP_TEST_IF(HasToggleEnabled("use_tint_generator"));
// TODO(crbug.com/dawn/644): Diagnose and fix this ANGLE failure.
DAWN_SKIP_TEST_IF(IsANGLE());
// TODO(crbug.com/dawn/672): Work around or enforce via validation that sample variables are not
// supported on some platforms.
DAWN_SKIP_TEST_IF(HasToggleEnabled("disable_sample_variables"));
wgpu::TextureView multisampledColorView2 =
CreateTextureForRenderAttachment(kColorFormat, kSampleCount).CreateView();