From f1bad6e15fb5d34fb7269936068fc2540b461a4f Mon Sep 17 00:00:00 2001 From: notaz Date: Thu, 10 Feb 2011 01:16:49 +0200 Subject: [PATCH] dfxvideo: fix frameskip issue if display is never moved/resized, it's never updated in frameskip mode. Detect this. --- plugins/dfxvideo/gpu.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/plugins/dfxvideo/gpu.c b/plugins/dfxvideo/gpu.c index 7372ba4a..50d45d59 100644 --- a/plugins/dfxvideo/gpu.c +++ b/plugins/dfxvideo/gpu.c @@ -218,6 +218,8 @@ static void updateDisplay(void) // UPDATE DISPLAY bSkipNextFrame = FALSE; DoBufferSwap(); // -> swap } + + bDoVSyncUpdate=FALSE; // vsync done } //////////////////////////////////////////////////////////////////////// @@ -406,11 +408,14 @@ void CALLBACK GPUupdateLace(void) // VSYNC } else { - if(bDoVSyncUpdate && !UseFrameSkip) // some primitives drawn? - updateDisplay(); // -> update display + if((bDoVSyncUpdate && !UseFrameSkip) // some primitives drawn? + || bDoVSyncUpdate >= 8) // not syned for a while + updateDisplay(); // -> update display } } - bDoVSyncUpdate=FALSE; // vsync done + + if(bDoVSyncUpdate) // if display not synced + bDoVSyncUpdate++; // count how many times } //////////////////////////////////////////////////////////////////////// -- 2.39.5