mirror of https://github.com/auygun/kaliber.git
Fix for Vulkan renderer
Terminate the bg thread before destroying resources
This commit is contained in:
parent
3bc8785469
commit
00f57bab05
|
@ -987,13 +987,13 @@ void RendererVulkan::Shutdown() {
|
||||||
return;
|
return;
|
||||||
|
|
||||||
LOG << "Shutting down renderer.";
|
LOG << "Shutting down renderer.";
|
||||||
DestroyAllResources();
|
|
||||||
context_lost_ = true;
|
|
||||||
|
|
||||||
quit_.store(true, std::memory_order_relaxed);
|
quit_.store(true, std::memory_order_relaxed);
|
||||||
semaphore_.release();
|
semaphore_.release();
|
||||||
setup_thread_.join();
|
setup_thread_.join();
|
||||||
|
|
||||||
|
DestroyAllResources();
|
||||||
|
context_lost_ = true;
|
||||||
|
|
||||||
vkDeviceWaitIdle(device_);
|
vkDeviceWaitIdle(device_);
|
||||||
|
|
||||||
for (size_t i = 0; i < frames_.size(); ++i) {
|
for (size_t i = 0; i < frames_.size(); ++i) {
|
||||||
|
|
Loading…
Reference in New Issue