From 1278e230f30773137d3b503031c8d3669f681e02 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Tue, 15 Feb 2022 15:22:52 -0500 Subject: Fix linux gfx issue (#2131) * #include an absolute path didn't work - because paths were taken to always be relative. * Fix linux build issue with renderer-shared.h * Move to .cpp file. * Move some templates to stop definition order issue on linux. * Move to header because it's templated. * Fix warning about GeometryInstanceFlags::Enum flags : 8; being too small by making the enum backed by 8 bits. * Check if vkDestroySampler function is available. --- tools/gfx/vulkan/render-vk.cpp | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'tools/gfx/vulkan/render-vk.cpp') diff --git a/tools/gfx/vulkan/render-vk.cpp b/tools/gfx/vulkan/render-vk.cpp index eb4044639..3d77fc50b 100644 --- a/tools/gfx/vulkan/render-vk.cpp +++ b/tools/gfx/vulkan/render-vk.cpp @@ -6395,7 +6395,10 @@ VKDevice::~VKDevice() shaderCache.free(); m_deviceObjectsWithPotentialBackReferences.clearAndDeallocate(); - m_api.vkDestroySampler(m_device, m_defaultSampler, nullptr); + if (m_api.vkDestroySampler) + { + m_api.vkDestroySampler(m_device, m_defaultSampler, nullptr); + } m_deviceQueue.destroy(); -- cgit v1.2.3