Fix output for missing Vulkan surface extensions

When the Vulkan loader is present but there are no required surface
extensions, as will for example happen with the Null platform, glfwinfo
caused an error in glfwGetPhysicalDevicePresentationSupport and produced
confusing output.
This commit is contained in:
Camilla Löwy 2021-10-06 19:49:34 +02:00
parent 4be0444ee6
commit 1d8d1ff3d0

View File

@ -954,6 +954,8 @@ int main(int argc, char** argv)
uint32_t qfp_count; uint32_t qfp_count;
vkGetPhysicalDeviceQueueFamilyProperties(pd[i], &qfp_count, NULL); vkGetPhysicalDeviceQueueFamilyProperties(pd[i], &qfp_count, NULL);
if (re)
{
printf("Vulkan device queue family presentation support:\n"); printf("Vulkan device queue family presentation support:\n");
for (uint32_t j = 0; j < qfp_count; j++) for (uint32_t j = 0; j < qfp_count; j++)
{ {
@ -963,6 +965,7 @@ int main(int argc, char** argv)
else else
printf("no\n"); printf("no\n");
} }
}
if (list_extensions) if (list_extensions)
list_vulkan_device_extensions(instance, pd[i]); list_vulkan_device_extensions(instance, pd[i]);