Skip to content

Commit

Permalink
Merge pull request #11813 from unknownbrackets/lagsync
Browse files Browse the repository at this point in the history
Core: Fix lag sync on game start / after pause
  • Loading branch information
hrydgard authored Feb 19, 2019
2 parents 04829c3 + 11be1e7 commit a0d4aba
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions Core/HLE/sceDisplay.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -180,6 +180,11 @@ void __DisplayFlip(int cyclesLate);
static void ScheduleLagSync(int over = 0) {
lagSyncScheduled = g_Config.bForceLagSync;
if (lagSyncScheduled) {
// Reset over if it became too high, such as after pausing or initial loading.
// There's no real sense in it being more than 1/60th of a second.
if (over > 1000000 / 60) {
over = 0;
}
CoreTiming::ScheduleEvent(usToCycles(1000 + over), lagSyncEvent, 0);
lastLagSync = real_time_now();
}
Expand Down

0 comments on commit a0d4aba

Please sign in to comment.