diff --git a/physical_device.cpp b/physical_device.cpp index c69c2cc..1fd792b 100644 --- a/physical_device.cpp +++ b/physical_device.cpp @@ -59,6 +59,21 @@ physical_device::features (void) const } +/////////////////////////////////////////////////////////////////////////////// +std::vector +physical_device::queue_families (void) const +{ + uint32_t count = 0; + vkGetPhysicalDeviceQueueFamilyProperties (id (), &count, nullptr); + + std::vector values (count); + vkGetPhysicalDeviceQueueFamilyProperties (id (), &count, values.data ()); + + values.resize (count); + return values; +} + + /////////////////////////////////////////////////////////////////////////////// std::string physical_device::name (void) const diff --git a/physical_device.hpp b/physical_device.hpp index 1a70b7c..0e12bf3 100644 --- a/physical_device.hpp +++ b/physical_device.hpp @@ -34,6 +34,8 @@ namespace cruft::vk { VkPhysicalDeviceProperties properties (void) const; VkPhysicalDeviceFeatures features (void) const; + std::vector queue_families (void) const; + std::string name (void) const; }; }