From 47bb2a1e9cc9974628ff36ecd43c8609f5a55a1b Mon Sep 17 00:00:00 2001 From: Toni Wilen Date: Wed, 24 Aug 2016 19:12:16 +0300 Subject: [PATCH] Low latency vsync fix. --- od-win32/win32gfx.cpp | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/od-win32/win32gfx.cpp b/od-win32/win32gfx.cpp index a9f64781..fbe431a1 100644 --- a/od-win32/win32gfx.cpp +++ b/od-win32/win32gfx.cpp @@ -3148,10 +3148,10 @@ static bool getvblankpos (int *vp, bool updateprev) } if (maxscanline > minscanline) { sl += scanline_adjust; - while (sl < 0) - sl += maxscanline; + while (sl < -1) + sl += maxscanline + 2; while (sl > maxscanline) - sl -= maxscanline; + sl -= maxscanline + 2; } *vp = sl; return true; -- 2.47.3