Vulkan: Update uniforms bugfix and enable dEQP tests with it
If a uniform was already marked as dirty, and the call to
setMatrixUniform wasn't updating the data, the flag was flipped
to false, causing the descriptor set never to be initialized.
This enables these tests:
dEQP-GLES2.functional.shaders.conversions.scalar_to_matrix.*
Bug: angleproject:2583
Change-Id: I0bcb95cc66951e0ed347af5d874178c403a1c08a
Reviewed-on: https://chromium-review.googlesource.com/1085228
Reviewed-by: Jamie Madill <jmadill@chromium.org>
Commit-Queue: Luc Ferron <lucferron@chromium.org>
diff --git a/src/libANGLE/renderer/vulkan/ProgramVk.cpp b/src/libANGLE/renderer/vulkan/ProgramVk.cpp
index de78ac4..d0b8660 100644
--- a/src/libANGLE/renderer/vulkan/ProgramVk.cpp
+++ b/src/libANGLE/renderer/vulkan/ProgramVk.cpp
@@ -581,9 +581,14 @@
continue;
}
- uniformBlock.uniformsDirty = SetFloatUniformMatrix<cols, rows>(
+ bool updated = SetFloatUniformMatrix<cols, rows>(
locationInfo.arrayIndex, linkedUniform.getArraySizeProduct(), count, transpose, value,
uniformBlock.uniformData.data() + layoutInfo.offset);
+
+ // If the uniformsDirty flag was true, we don't want to flip it to false here if the
+ // setter did not update any data. We still want the uniform to be included when we'll
+ // update the descriptor sets.
+ uniformBlock.uniformsDirty = uniformBlock.uniformsDirty || updated;
}
}