From 7e5a1d0859c6ea3c767c0f1ba3d7050b69681c19 Mon Sep 17 00:00:00 2001 From: scribam Date: Tue, 16 Nov 2021 23:07:57 +0100 Subject: [PATCH] Compatibility fix with old sdks where VK_ERROR_UNKNOWN is not defined --- include/vk_mem_alloc.h | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/include/vk_mem_alloc.h b/include/vk_mem_alloc.h index 2967c58..53c773c 100644 --- a/include/vk_mem_alloc.h +++ b/include/vk_mem_alloc.h @@ -150,6 +150,10 @@ available through VmaAllocatorCreateInfo::pRecordSettings. #include #endif +#if !defined(VK_VERSION_1_2) + #define VK_ERROR_UNKNOWN ((VkResult)-13) +#endif + // Define this macro to declare maximum supported Vulkan version in format AAABBBCCC, // where AAA = major, BBB = minor, CCC = patch. // If you want to use version > 1.0, it still needs to be enabled via VmaAllocatorCreateInfo::vulkanApiVersion.