From f576a3edbd003797df3ca6995160e093f14c9f9d Mon Sep 17 00:00:00 2001 From: Chris Forbes Date: Sun, 21 Jun 2015 22:55:02 +1200 Subject: vulkan.h: Remove vkGetFormatInfo, add features/limits (#12827, v125) NOTES: 1/ Some layers impact from vkGetFormatInfo -> vkGetPhysicalDeviceFormatInfo; some checks are currently disabled in ParamChecker pending discussion on the best way to do this. Similar checks in Image layer implemented via additional layer_data member to link back from VkDevice -> VkPhysicalDevice. 2/ VkPhysicalDeviceFeatures, VkPhysicalDeviceLimits members all zero for now; also some further churn to be done to the contents of these structures. Signed-off-by: Chris Forbes --- layers/basic.cpp | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) (limited to 'layers/basic.cpp') diff --git a/layers/basic.cpp b/layers/basic.cpp index d6ea963a..59ec08d4 100644 --- a/layers/basic.cpp +++ b/layers/basic.cpp @@ -133,11 +133,11 @@ VK_LAYER_EXPORT VkResult VKAPI vkDestroyInstance(VkInstance instance) return res; } -VK_LAYER_EXPORT VkResult VKAPI vkGetFormatInfo(VkDevice device, VkFormat format, VkFormatInfoType infoType, size_t* pDataSize, void* pData) +VK_LAYER_EXPORT VkResult VKAPI vkGetPhysicalDeviceFormatInfo(VkPhysicalDevice gpu, VkFormat format, VkFormatProperties *pFormatInfo) { - printf("At start of wrapped vkGetFormatInfo() call w/ device: %p\n", (void*)device); - VkResult result = device_dispatch_table(device)->GetFormatInfo(device, format, infoType, pDataSize, pData); - printf("Completed wrapped vkGetFormatInfo() call w/ device: %p\n", (void*)device); + printf("At start of wrapped vkGetPhysicalDeviceFormatInfo() call w/ gpu: %p\n", (void*)gpu); + VkResult result = instance_dispatch_table(gpu)->GetPhysicalDeviceFormatInfo(gpu, format, pFormatInfo); + printf("Completed wrapped vkGetPhysicalDeviceFormatInfo() call w/ gpu: %p\n", (void*)gpu); return result; } @@ -152,8 +152,6 @@ VK_LAYER_EXPORT void * VKAPI vkGetDeviceProcAddr(VkDevice device, const char* pN return (void *) vkGetDeviceProcAddr; } - if (!strcmp("vkGetFormatInfo", pName)) - return (void *) vkGetFormatInfo; if (!strcmp("vkDestroyDevice", pName)) return (void *) vkDestroyDevice; if (!strcmp("vkLayerExtension1", pName)) @@ -176,6 +174,8 @@ VK_LAYER_EXPORT void * VKAPI vkGetInstanceProcAddr(VkInstance instance, const ch initInstanceTable((const VkBaseLayerObject *) instance); return (void *) vkGetInstanceProcAddr; } + if (!strcmp("vkGetPhysicalDeviceFormatInfo", pName)) + return (void *) vkGetPhysicalDeviceFormatInfo; if (!strcmp("vkDestroyInstance", pName)) return (void *) vkDestroyInstance; -- cgit v1.2.3