mirror of
https://github.com/godotengine/godot-angle-static.git
synced 2026-01-03 14:09:33 +03:00
Add regression test for VVL AlphaToCoverage bug
https://github.com/KhronosGroup/Vulkan-ValidationLayers/issues/5520 Bug: b/264062978 Change-Id: I0619cb28495c16d0d8d83635ad7a93f0c47cea6b Reviewed-on: https://chromium-review.googlesource.com/c/angle/angle/+/4374098 Reviewed-by: Shahbaz Youssefi <syoussefi@chromium.org> Auto-Submit: Roman Lavrov <romanl@google.com> Commit-Queue: Roman Lavrov <romanl@google.com>
This commit is contained in:
committed by
Angle LUCI CQ
parent
a811356480
commit
59b0c7d718
@@ -5177,7 +5177,7 @@ void main(void)
|
||||
|
||||
glUseProgram(verifyProgram);
|
||||
|
||||
constexpr std::array<GLfloat, kImage2Size + kImageRows *kImageCols> kOutputInitData = {};
|
||||
constexpr std::array<GLfloat, kImage2Size + kImageRows * kImageCols> kOutputInitData = {};
|
||||
GLBuffer outputBuffer;
|
||||
glBindBuffer(GL_SHADER_STORAGE_BUFFER, outputBuffer);
|
||||
glBufferData(GL_SHADER_STORAGE_BUFFER, sizeof(kOutputInitData), kOutputInitData.data(),
|
||||
@@ -10293,6 +10293,18 @@ TEST_P(GLSLTest, FragData)
|
||||
EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::red);
|
||||
}
|
||||
|
||||
// Tests using gl_FragData[0] instead of gl_FragColor with GL_SAMPLE_ALPHA_TO_COVERAGE
|
||||
// Regression test for https://github.com/KhronosGroup/Vulkan-ValidationLayers/issues/5520
|
||||
TEST_P(GLSLTest, FragData_AlphaToCoverage)
|
||||
{
|
||||
constexpr char kFS[] = R"(void main() { gl_FragData[0] = vec4(1, 0, 0, 1); })";
|
||||
ANGLE_GL_PROGRAM(program, essl1_shaders::vs::Simple(), kFS);
|
||||
glEnable(GL_SAMPLE_ALPHA_TO_COVERAGE);
|
||||
drawQuad(program, essl1_shaders::PositionAttrib(), 0.5f);
|
||||
EXPECT_GL_NO_ERROR();
|
||||
EXPECT_PIXEL_COLOR_EQ(0, 0, GLColor::red);
|
||||
}
|
||||
|
||||
// Test angle can handle big initial stack size with dynamic stack allocation.
|
||||
TEST_P(GLSLTest, MemoryExhaustedTest)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user