mirror of
https://github.com/mpv-player/mpv
synced 2025-02-06 15:11:58 +00:00
video: restore printing warning on decreasing filter PTS
Recently, the check was moved, so it was printed only for source video PTS (since that's easier, and filters should normally behave sane). But it turns out it's trivial to print a warning in the filter case too by reusing the code that normally checks for PTS forward jumps without needing any additional code, so, fine, restore warning in this case.
This commit is contained in:
parent
9edc2dbcf3
commit
54f15bd377
@ -327,8 +327,8 @@ double update_video(struct MPContext *mpctx, double endpts)
|
||||
double last_pts = mpctx->video_next_pts;
|
||||
if (last_pts == MP_NOPTS_VALUE)
|
||||
last_pts = pts;
|
||||
double frame_time = MPMAX(0, pts - last_pts);
|
||||
if (frame_time >= 60) {
|
||||
double frame_time = pts - last_pts;
|
||||
if (frame_time < 0 || frame_time >= 60) {
|
||||
// Assume a PTS difference >= 60 seconds is a discontinuity.
|
||||
MP_WARN(mpctx, "Jump in video pts: %f -> %f\n", last_pts, pts);
|
||||
frame_time = 0;
|
||||
|
Loading…
Reference in New Issue
Block a user