texture3d checks wrong type of flag (TRANSFER_DST)

Test is checking that the format supports being a transfer destination
but is checking the optimalTilingFeatures against an image usage flag
(VK_IMAGE_USAGE_TRANSFER_DST_BIT) instead of a format feature flag
(VK_FORMAT_FEATURE_TRANSFER_DST_BIT) which have different values.

Otherwise the test believes the device does not support the required
format and quits.
This commit is contained in:
Alex Walters 2018-05-04 16:52:21 +01:00
parent ee9043d956
commit fd152cf176

View file

@ -234,7 +234,7 @@ public:
VkFormatProperties formatProperties;
vkGetPhysicalDeviceFormatProperties(physicalDevice, texture.format, &formatProperties);
// Check if format supports transfer
if (!(formatProperties.optimalTilingFeatures & VK_IMAGE_USAGE_TRANSFER_DST_BIT))
if (!(formatProperties.optimalTilingFeatures & VK_FORMAT_FEATURE_TRANSFER_DST_BIT))
{
std::cout << "Error: Device does not support flag TRANSFER_DST for selected texture format!" << std::endl;
return;