Problem while running the example SoftwareRasterization
Ubuntu 18.01
GeForce GTX 1080 Selected device: GeForce GTX 1080 IMAGE(ERROR / SPEC): object: 0x0 type: 0 msgNum: 165676966 - vkCreateImage: usage bit VK_IMAGE_USAGE_STORAGE_BIT is not supported for format VK_FORMAT_B8G8R8A8_UNORM with tiling VK_IMAGE_TILING_LINEAR. The spec valid usage text states 'If tiling is VK_IMAGE_TILING_LINEAR, and VkFormatProperties::linearTilingFeatures (as returned by vkGetPhysicalDeviceFormatProperties with the same value of format) does not include VK_FORMAT_FEATURE_STORAGE_IMAGE_BIT, usage must not contain VK_IMAGE_USAGE_STORAGE_BIT' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageCreateInfo-tiling-00979) IMAGE(ERROR): object: 0x0 type: 0 location: 663 msg_code: 165676966: Object: 0x0 | vkCreateImage: usage bit VK_IMAGE_USAGE_STORAGE_BIT is not supported for format VK_FORMAT_B8G8R8A8_UNORM with tiling VK_IMAGE_TILING_LINEAR. The spec valid usage text states 'If tiling is VK_IMAGE_TILING_LINEAR, and VkFormatProperties::linearTilingFeatures (as returned by vkGetPhysicalDeviceFormatProperties with the same value of format) does not include VK_FORMAT_FEATURE_STORAGE_IMAGE_BIT, usage must not contain VK_IMAGE_USAGE_STORAGE_BIT' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageCreateInfo-tiling-00979) IMAGE(ERROR / SPEC): object: 0x0 type: 0 msgNum: 165676888 - vkCreateImage: The combination of format, type, tiling, usage and flags supplied in the VkImageCreateInfo struct is reported by vkGetPhysicalDeviceImageFormatProperties() as unsupported. The spec valid usage text states 'The combination of format, imageType, tiling, usage, and flags must be supported, as indicated by a VK_SUCCESS return value from vkGetPhysicalDeviceImageFormatProperties invoked with the same values passed to the corresponding parameters.' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageCreateInfo-format-00940) IMAGE(ERROR): object: 0x0 type: 0 location: 708 msg_code: 165676888: Object: 0x0 | vkCreateImage: The combination of format, type, tiling, usage and flags supplied in the VkImageCreateInfo struct is reported by vkGetPhysicalDeviceImageFormatProperties() as unsupported. The spec valid usage text states 'The combination of format, imageType, tiling, usage, and flags must be supported, as indicated by a VK_SUCCESS return value from vkGetPhysicalDeviceImageFormatProperties invoked with the same values passed to the corresponding parameters.' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageCreateInfo-format-00940) ParameterValidation(ERROR / SPEC): object: 0x0 type: 0 msgNum: 4 - vkCmdPipelineBarrier: required parameter pImageMemoryBarriers[0].image specified as VK_NULL_HANDLE ParameterValidation(ERROR): object: 0x0 type: 0 location: 436 msg_code: 4: Object: 0x0 | vkCmdPipelineBarrier: required parameter pImageMemoryBarriers[0].image specified as VK_NULL_HANDLE ObjectTracker(ERROR / SPEC): object: 0x0 type: 10 msgNum: 167813121 - Invalid Image Object 0x0. The spec valid usage text states 'image must be a valid VkImage handle' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageMemoryBarrier-image-parameter) ObjectTracker(ERROR): object: 0x0 type: 10 location: 198 msg_code: 167813121: Object: 0x0 | Invalid Image Object 0x0. The spec valid usage text states 'image must be a valid VkImage handle' (https://www.khronos.org/registry/vulkan/specs/1.0/html/vkspec.html#VUID-VkImageMemoryBarrier-image-parameter) [1] 24237 segmentation fault (core dumped) ./SoftwareRasterization
I have encountered this issue with NVIDIA’s driver. It only supports R8G8B8A8 for storage images with linear tiling. This is independent of V-EZ itself however and is the application’s responsibility for validating format, usage and layout support. I’ll implement proper checking in the demo itself.
If anyone is having trouble running this example on an Nvidia GPU Just change this line https://github.com/GPUOpen-LibrariesAndSDKs/V-EZ/blob/29d2229e44ee692f74a33b698c80273ebcc67c3e/Samples/SoftwareRasterization/SoftwareRasterization.cpp#L168 to
imageCreateInfo.tiling = VK_IMAGE_TILING_OPTIMAL;
Tested on a Quadro K2000M, on 426.00. Windows 10.