Format properties for format used for color attachment must contain
VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT
Components: Vulkan
VK-GL-CTS issue: 4156
Affected tests:
dEQP-VK.memory.external_memory_host.bind_image_memory_and_render.*
Change-Id: Ib0346cbc849b94a5af67e5645cc057ca392f9b2f
// Verify image format properties before proceeding.
verifyFormatProperties(m_testParams.m_format, tiling, usageFlags);
+ VkFormatProperties formatProperties;
+ m_vki.getPhysicalDeviceFormatProperties(m_physicalDevice, m_testParams.m_format, &formatProperties);
+ if ((formatProperties.linearTilingFeatures & VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT) != VK_FORMAT_FEATURE_COLOR_ATTACHMENT_BIT)
+ TCU_THROW(NotSupportedError, "Format does not support linear tiling for color attachment");
+
// Create image with external host memory.
m_image = createImage(m_testParams.m_format, tiling, usageFlags);