mirror of
https://github.com/mpv-player/mpv
synced 2025-03-20 02:09:52 +00:00
player: don't make display-sync panic on timestamp discontinuities
This commit is contained in:
parent
68c6da69f7
commit
832cb56f2d
@ -964,9 +964,9 @@ static void handle_display_sync_frame(struct MPContext *mpctx,
|
||||
if (vsync <= 0)
|
||||
return;
|
||||
|
||||
double adjusted_duration = mpctx->past_frames[0].approx_duration;
|
||||
double adjusted_duration = MPMAX(0, mpctx->past_frames[0].approx_duration);
|
||||
adjusted_duration /= opts->playback_speed;
|
||||
if (adjusted_duration <= 0.001 || adjusted_duration > 0.5)
|
||||
if (adjusted_duration > 0.5)
|
||||
return;
|
||||
|
||||
mpctx->speed_factor_v = 1.0;
|
||||
|
Loading…
Reference in New Issue
Block a user