Qt: Simplify emulation thread loop

This commit is contained in:
Connor McLaughlin 2020-02-09 22:16:37 +09:00
parent c820ddba79
commit 2bf6912f39
1 changed files with 7 additions and 18 deletions

View File

@ -590,30 +590,19 @@ void QtHostInterface::threadEntryPoint()
continue;
}
// execute the system, polling events inbetween frames
// simulate the system if not paused
m_system->RunFrame();
// rendering
{
if (m_system)
{
DrawDebugWindows();
m_system->GetGPU()->ResetGraphicsAPIState();
}
DrawDebugWindows();
DrawOSDMessages();
m_display->Render();
if (m_system)
{
m_system->GetGPU()->RestoreGraphicsAPIState();
if (m_speed_limiter_enabled)
m_system->Throttle();
}
}
m_worker_thread_event_loop->processEvents(QEventLoop::AllEvents);
}