diff options
author | wm4 <wm4@nowhere> | 2014-08-03 20:25:03 +0200 |
---|---|---|
committer | wm4 <wm4@nowhere> | 2014-08-03 20:31:00 +0200 |
commit | 0f5aed9c62cb29a53dc1039df786207a2bd80d85 (patch) | |
tree | 1f307ee9f2b62d47b12ee9fb8cc487d9f41cd005 /player/video.c | |
parent | 0ddbf92d067e342ef58fbd60e1c4871feba83ea5 (diff) | |
download | mpv-0f5aed9c62cb29a53dc1039df786207a2bd80d85.tar.bz2 mpv-0f5aed9c62cb29a53dc1039df786207a2bd80d85.tar.xz |
player: some further playloop cleanups
Handle --term-playing-msg at a better place.
Move MPV_EVENT_TICK hack into a separate function. Also add some words
to the client API that you shouldn't use it. (But better leave breaking
it for later.)
Handle --frames and frame_step differently. Remove the mess from the
playloop, and do it after frame display. Give up on the weird semantics
for audio-only mode (they didn't make sense anyway), and adjust the
manpage accordingly.
Diffstat (limited to 'player/video.c')
-rw-r--r-- | player/video.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/player/video.c b/player/video.c index 7d33538627..c0e1101858 100644 --- a/player/video.c +++ b/player/video.c @@ -896,4 +896,16 @@ void write_video(struct MPContext *mpctx, double endpts) if (!mpctx->sync_audio_to_video) mpctx->video_status = STATUS_EOF; + + if (mpctx->video_status != STATUS_EOF) { + if (mpctx->step_frames > 0) { + mpctx->step_frames--; + if (!mpctx->step_frames && !opts->pause) + pause_player(mpctx); + } + if (mpctx->max_frames == 0) + mpctx->stop_play = PT_NEXT_ENTRY; + if (mpctx->max_frames > 0) + mpctx->max_frames--; + } } |