diff --git a/physical_device.cpp b/physical_device.cpp index e828e7c..58527da 100644 --- a/physical_device.cpp +++ b/physical_device.cpp @@ -63,12 +63,19 @@ physical_device::features (void) const VkSurfaceCapabilitiesKHR physical_device::surface_capabilities (VkSurfaceKHR surface) const { - VkSurfaceCapabilitiesKHR value; - error::try_func ( - &vkGetPhysicalDeviceSurfaceCapabilitiesKHR, id (), surface, &value + return error::try_query ( + vkGetPhysicalDeviceSurfaceCapabilitiesKHR, id (), surface ); +} - return value; + +//----------------------------------------------------------------------------- +VkPhysicalDeviceMemoryProperties +physical_device::memory_properties (void) const +{ + return error::try_query ( + vkGetPhysicalDeviceMemoryProperties, id () + ); } diff --git a/physical_device.hpp b/physical_device.hpp index f943022..65a29b6 100644 --- a/physical_device.hpp +++ b/physical_device.hpp @@ -34,6 +34,7 @@ namespace cruft::vk { VkPhysicalDeviceProperties properties (void) const; VkPhysicalDeviceFeatures features (void) const; VkSurfaceCapabilitiesKHR surface_capabilities (VkSurfaceKHR) const; + VkPhysicalDeviceMemoryProperties memory_properties (void) const; std::vector queue_families (void) const;