From 2fd4453de60e9759687e9b44bff56fef960a02cc Mon Sep 17 00:00:00 2001 From: bailwillharr Date: Sat, 8 Oct 2022 16:20:31 +0100 Subject: [PATCH] Add vma --- .gitmodules | 3 +++ dependencies/VulkanMemoryAllocator | 1 + src/engine.cpp | 2 +- src/gfx_device_vulkan.cpp | 1 + 4 files changed, 6 insertions(+), 1 deletion(-) create mode 160000 dependencies/VulkanMemoryAllocator diff --git a/.gitmodules b/.gitmodules index 9e12f3b..d064ea5 100644 --- a/.gitmodules +++ b/.gitmodules @@ -19,3 +19,6 @@ [submodule "dependencies/volk"] path = dependencies/volk url = https://github.com/zeux/volk +[submodule "dependencies/VulkanMemoryAllocator"] + path = dependencies/VulkanMemoryAllocator + url = https://github.com/GPUOpen-LibrariesAndSDKs/VulkanMemoryAllocator diff --git a/dependencies/VulkanMemoryAllocator b/dependencies/VulkanMemoryAllocator new file mode 160000 index 0000000..c351692 --- /dev/null +++ b/dependencies/VulkanMemoryAllocator @@ -0,0 +1 @@ +Subproject commit c351692490513cdb0e5a2c925aaf7ea4a9b672f4 diff --git a/src/engine.cpp b/src/engine.cpp index 44b4112..37f7175 100644 --- a/src/engine.cpp +++ b/src/engine.cpp @@ -7,7 +7,7 @@ namespace engine { Application::Application(const char* appName, const char* appVersion) { - m_win = std::make_unique(appName, true); + m_win = std::make_unique(appName, false); m_gfx = std::make_unique(appName, appVersion, m_win->getHandle()); } diff --git a/src/gfx_device_vulkan.cpp b/src/gfx_device_vulkan.cpp index 60fac9d..81442ac 100644 --- a/src/gfx_device_vulkan.cpp +++ b/src/gfx_device_vulkan.cpp @@ -952,6 +952,7 @@ namespace engine { DepthStencil& operator=(const DepthStencil&) = delete; ~DepthStencil() { + TRACE("Destroying DepthStencil..."); vkDestroyImageView(m_device->getHandle(), m_imageView, nullptr); vkFreeMemory(m_device->getHandle(), m_imageMemory, nullptr); vkDestroyImage(m_device->getHandle(), m_image, nullptr);