Without this change, if any driver doesn't support that feature, then
non-indirect draw calls, like vkCmdDrawIndexed are also tested using
only firstInstance==0.
Affects:
dEQP-VK.draw.instanced.*
Components: Vulkan
VK-GL-CTS issue: 2857
Change-Id: I432d5760258848d30e101baf702495980d2116fe
qpTestResult res = QP_TEST_RESULT_PASS;
const vk::VkClearColorValue clearColor = { { 0.0f, 0.0f, 0.0f, 1.0f } };
- int firstInstanceIndicesCount = 1;
+ int firstInstanceIndicesCount = DE_LENGTH_OF_ARRAY(firstInstanceIndices);
// Require 'drawIndirectFirstInstance' feature to run non-zero firstInstance indirect draw tests.
- if (m_context.getDeviceFeatures().drawIndirectFirstInstance)
- firstInstanceIndicesCount = DE_LENGTH_OF_ARRAY(firstInstanceIndices);
+ if (m_params.function == TestParams::FUNCTION_DRAW_INDIRECT && !m_context.getDeviceFeatures().drawIndirectFirstInstance)
+ {
+ firstInstanceIndicesCount = 1;
+ }
for (int instanceCountNdx = 0; instanceCountNdx < DE_LENGTH_OF_ARRAY(instanceCounts); instanceCountNdx++)
{