player: add some debug output for seeking

This commit is contained in:
wm4 2015-06-18 22:31:55 +02:00
parent d328b2088c
commit b1a56d11fe
3 changed files with 12 additions and 0 deletions

View File

@ -527,9 +527,13 @@ static void execute_seek(struct demux_internal *in)
pthread_mutex_unlock(&in->lock);
MP_VERBOSE(in, "execute seek (to %f flags %d)\n", pts, flags);
if (in->d_thread->desc->seek)
in->d_thread->desc->seek(in->d_thread, pts, flags);
MP_VERBOSE(in, "seek done\n");
pthread_mutex_lock(&in->lock);
}
@ -1124,6 +1128,9 @@ int demux_seek(demuxer_t *demuxer, double rel_seek_secs, int flags)
pthread_mutex_lock(&in->lock);
MP_VERBOSE(in, "queuing seek to %f%s\n", rel_seek_secs,
in->seeking ? " (cascade)" : "");
flush_locked(demuxer);
in->seeking = true;
in->seek_flags = flags;

View File

@ -287,6 +287,9 @@ static int mp_seek(MPContext *mpctx, struct seek_params seek,
mpctx->hrseek_framedrop = !hr_seek_very_exact;
mpctx->hrseek_pts = hr_seek ? seek.amount
: mpctx->timeline[mpctx->timeline_part].start;
MP_VERBOSE(mpctx, "hr-seek, skipping to %f%s\n", mpctx->hrseek_pts,
mpctx->hrseek_framedrop ? "" : " (no framedrop)");
}
mpctx->start_timestamp = mp_time_sec();
@ -960,6 +963,7 @@ static void handle_playback_restart(struct MPContext *mpctx, double endpts)
}
}
mpctx->playing_msg_shown = true;
MP_VERBOSE(mpctx, "playback restart complete\n");
}
}

View File

@ -887,6 +887,7 @@ void write_video(struct MPContext *mpctx, double endpts)
mpctx->video_status = STATUS_READY;
// After a seek, make sure to wait until the first frame is visible.
vo_wait_frame(vo);
MP_VERBOSE(mpctx, "first video frame after restart shown\n");
}
screenshot_flip(mpctx);