From cf503553eb44f104072d8add4069f8352f7bad22 Mon Sep 17 00:00:00 2001 From: jsmall-nvidia Date: Thu, 23 Jul 2020 09:37:58 -0400 Subject: Fix for vulkan tests failing (#1456) * Clean up device when VKRenderer dtor is run. Added destroy methods to VulkanSwapChain & VulkanDeviceQueue * Small fixes around testing if DeviceQueue is valid. * Disable active-mask tests. Different drivers appear to change the results. --- tools/gfx/vulkan/vk-swap-chain.cpp | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) (limited to 'tools/gfx/vulkan/vk-swap-chain.cpp') diff --git a/tools/gfx/vulkan/vk-swap-chain.cpp b/tools/gfx/vulkan/vk-swap-chain.cpp index 5cf2e96ae..d9b3a495d 100644 --- a/tools/gfx/vulkan/vk-swap-chain.cpp +++ b/tools/gfx/vulkan/vk-swap-chain.cpp @@ -348,7 +348,7 @@ void VulkanSwapChain::_destroySwapChain() m_images.clear(); } -VulkanSwapChain::~VulkanSwapChain() +void VulkanSwapChain::destroy() { _destroySwapChain(); @@ -359,6 +359,12 @@ VulkanSwapChain::~VulkanSwapChain() } } + +VulkanSwapChain::~VulkanSwapChain() +{ + destroy(); +} + int VulkanSwapChain::nextFrontImageIndex() { if (!hasValidSwapChain()) -- cgit v1.2.3