0
0
mirror of https://github.com/mpv-player/mpv.git synced 2024-09-20 03:52:22 +02:00

player: move point at which queued seeks are applied

Do it after decoding etc., but before waiting for input. This seems to
make more sense, because whether a queued seek can be applied depends on
the playback state. So it sounds like a good idea to apply the seek
first thing, but it's a bad idea to go to sleep if there's still a
queued seek pending (that couldn't be processed earlier).

Also add an empty line before mp_wait_events(); it doesn't really have
to do with the filter bullshit.
This commit is contained in:
wm4 2019-12-14 14:18:10 +01:00
parent 57fbc9cd76
commit 1f1d2d5f49

View File

@ -1239,6 +1239,8 @@ void run_playloop(struct MPContext *mpctx)
update_core_idle_state(mpctx);
execute_queued_seek(mpctx);
if (mpctx->stop_play)
return;
@ -1246,6 +1248,7 @@ void run_playloop(struct MPContext *mpctx)
if (mp_filter_run(mpctx->filter_root))
mp_wakeup_core(mpctx);
mp_wait_events(mpctx);
handle_update_cache(mpctx);
@ -1255,8 +1258,6 @@ void run_playloop(struct MPContext *mpctx)
handle_chapter_change(mpctx);
handle_force_window(mpctx, false);
execute_queued_seek(mpctx);
}
void mp_idle(struct MPContext *mpctx)