From d563dc8cb94e6313871646ca51f502f9db19b177 Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 29 Jul 2014 00:07:54 +0200 Subject: player: update playback position on seek If the actual PTS is not known yet right after a seek, the "time-pos" property will just return the seek target PTS. For this purpose, trigger a change event to make the client API update the "time-pos" and related properties. (MPV_EVENT_TICK triggers this update.) --- player/playloop.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/player/playloop.c b/player/playloop.c index f17f44311e..4f1af50afe 100644 --- a/player/playloop.c +++ b/player/playloop.c @@ -324,6 +324,8 @@ static int mp_seek(MPContext *mpctx, struct seek_params seek, mpctx->start_timestamp = mp_time_sec(); mpctx->sleeptime = 0; + mp_notify(mpctx, MPV_EVENT_TICK, NULL); + return 0; } -- cgit v1.2.3