mirror of
https://github.com/dolphin-emu/dolphin.git
synced 2025-07-23 14:19:46 -06:00
VideoBackends:Vulkan: Don't try to present if swapchain acquire failed
This commit is contained in:
@ -844,10 +844,10 @@ void Presenter::Present()
|
||||
UpdateDrawRectangle();
|
||||
|
||||
g_gfx->BeginUtilityDrawing();
|
||||
g_gfx->BindBackbuffer({{0.0f, 0.0f, 0.0f, 1.0f}});
|
||||
const bool backbuffer_bound = g_gfx->BindBackbuffer({{0.0f, 0.0f, 0.0f, 1.0f}});
|
||||
|
||||
// Render the XFB to the screen.
|
||||
if (m_xfb_entry)
|
||||
if (backbuffer_bound && m_xfb_entry)
|
||||
{
|
||||
// Adjust the source rectangle instead of using an oversized viewport to render the XFB.
|
||||
auto render_target_rc = GetTargetRectangle();
|
||||
@ -860,7 +860,8 @@ void Presenter::Present()
|
||||
if (m_onscreen_ui)
|
||||
{
|
||||
m_onscreen_ui->Finalize();
|
||||
m_onscreen_ui->DrawImGui();
|
||||
if (backbuffer_bound)
|
||||
m_onscreen_ui->DrawImGui();
|
||||
}
|
||||
|
||||
// Present to the window system.
|
||||
|
Reference in New Issue
Block a user