Skip to content

Commit

Permalink
inspector: Spell out Vulkan device types
Browse files Browse the repository at this point in the history
We know what these are, no need to be mysterious about it.
  • Loading branch information
Matthias Clasen committed Feb 12, 2024
1 parent 3c048ca commit efa0033
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion gtk/inspector/general.c
Original file line number Diff line number Diff line change
Expand Up @@ -513,11 +513,12 @@ init_vulkan (GtkInspectorGeneral *gen)
char *device_name;
char *api_version;
char *driver_version;
const char *types[] = { "other", "integrated GPU", "discrete GPU", "virtual GPU", "CPU" };

vk_device = gen->display->vk_physical_device;
vkGetPhysicalDeviceProperties (vk_device, &props);

device_name = g_strdup_printf ("%s (%d)", props.deviceName, props.deviceType);
device_name = g_strdup_printf ("%s (%s)", props.deviceName, types[props.deviceType]);
api_version = g_strdup_printf ("%d.%d.%d",
VK_VERSION_MAJOR (props.apiVersion),
VK_VERSION_MINOR (props.apiVersion),
Expand Down

0 comments on commit efa0033

Please sign in to comment.