From 411bcaa15de048f0de5515f41b6bec1323798708 Mon Sep 17 00:00:00 2001 From: retr0s4ge Date: Fri, 29 Jun 2018 14:23:01 +0200 Subject: [PATCH] Forcibly wait for the display thread to draw each frame (never skip any frame) ONLY IF the user set frame skip to "0 (never skip)". Current implementation causes significant display lag if any magnification filter is used while GPU scaling factor is >1. --- desmume/src/frontend/windows/main.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/desmume/src/frontend/windows/main.cpp b/desmume/src/frontend/windows/main.cpp index a1af64c88..db548f378 100755 --- a/desmume/src/frontend/windows/main.cpp +++ b/desmume/src/frontend/windows/main.cpp @@ -2292,7 +2292,7 @@ static void StepRunLoop_User() Hud.fps3d = GPU->GetFPSRender3D(); // wait for the HUD to update from last frame - WaitForSingleObject(display_done_event, display_done_timeout); + if(frameskiprate==0) WaitForSingleObject(display_done_event, display_done_timeout); Display(); mainLoopData.fps3d = Hud.fps3d;