mirror of
https://github.com/hrydgard/ppsspp.git
synced 2026-11-15 18:49:51 +01:00
Vulkan: Allow shutdown with init commands.
On startup, when immediately shutting down, there will be init commands from creating the backbuffers. Rather than fight this, just free them. This fixes hangs when locking/unlocking Android.
This commit is contained in:
1 parent
9c046d7518
commit
5846016247
1 file changed
+6
-2
@@ -225,8 +225,12 @@ void VulkanRenderManager::StopThread() {
|
||||
// when we restart...
|
||||
for (int i = 0; i < vulkan_->GetInflightFrames(); i++) {
|
||||
auto &frameData = frameData_[i];
|
||||
if (frameData.readyForRun || frameData.hasInitCommands || frameData.steps.size() != 0) {
|
||||
Crash();
|
||||
_assert_(!frameData.readyForRun);
|
||||
_assert_(frameData.steps.empty());
|
||||
if (frameData.hasInitCommands) {
|
||||
// Clear 'em out. This can happen on restart sometimes.
|
||||
vkEndCommandBuffer(frameData.initCmd);
|
||||
frameData.hasInitCommands = false;
|
||||
}
|
||||
frameData.readyForRun = false;
|
||||
for (size_t i = 0; i < frameData.steps.size(); i++) {
|
||||
|
||||
Reference in new issue
Block a user