Permalink
Browse files

Vulkan: Wait for queue idle in DestroyBackbuffers.

Otherwise it's only done after destroying Draw, so no need to mutex.
  • Loading branch information...
unknownbrackets committed Nov 5, 2017
1 parent efbba31 commit ebe9dcafde21a81aea29ea6895bde623eb768880
@@ -228,7 +228,6 @@ void WindowsVulkanContext::SwapBuffers() {
}
void WindowsVulkanContext::Resize() {
g_Vulkan->WaitUntilQueueIdle();
draw_->HandleEvent(Draw::Event::LOST_BACKBUFFER, g_Vulkan->GetBackbufferWidth(), g_Vulkan->GetBackbufferHeight());
g_Vulkan->DestroyObjects();
@@ -341,7 +341,6 @@ void AndroidVulkanContext::SwapBuffers() {
}
void AndroidVulkanContext::Resize() {
g_Vulkan->WaitUntilQueueIdle();
draw_->HandleEvent(Draw::Event::LOST_BACKBUFFER, g_Vulkan->GetBackbufferWidth(), g_Vulkan->GetBackbufferHeight());
g_Vulkan->DestroyObjects();
@@ -218,6 +218,8 @@ void VulkanRenderManager::DestroyBackbuffers() {
}
thread_.join();
}
vulkan_->WaitUntilQueueIdle();
VkDevice device = vulkan_->GetDevice();
for (uint32_t i = 0; i < swapchainImageCount_; i++) {
vulkan_->Delete().QueueDeleteImageView(swapchainImages_[i].view);

0 comments on commit ebe9dca

Please sign in to comment.