From c3c714b05903c26656e14c0bf229d873b73a0899 Mon Sep 17 00:00:00 2001 From: wm4 Date: Tue, 3 Feb 2015 23:09:02 +0100 Subject: player: remove --fixed-vo In ancient times, this was needed because it was not default, and many VOs had problems with it. But it was always default in mpv, and all VOs are required to deal with it. Also, running --fixed-vo=no is not useful and just creates weird corner cases. Get rid of it. --- DOCS/man/changes.rst | 3 ++- options/options.c | 4 +--- options/options.h | 1 - player/loadfile.c | 6 +----- player/main.c | 1 - player/video.c | 2 +- 6 files changed, 5 insertions(+), 12 deletions(-) diff --git a/DOCS/man/changes.rst b/DOCS/man/changes.rst index 6f57a1b14c..a4f3467b53 100644 --- a/DOCS/man/changes.rst +++ b/DOCS/man/changes.rst @@ -77,7 +77,7 @@ Video * High-quality image resamplers (see the ``opengl`` ``scale`` suboption). * Support for scaling in (sigmoidized) linear light. * Better subtitle rendering using libass by default. -* Improvements when playing multiple files (``--fixed-vo`` is default, do not +* Improvements when playing multiple files (``-fixed-vo`` is default, do not reset settings by default when playing a new file). * Replace image video outputs (``--vo=jpeg`` etc.) with ``--vo=image``. * Removal of ``--vo=gif89a``, ``--vo=md5sum``, ``--vo=yuv4mpeg``, as encoding @@ -215,6 +215,7 @@ Command Line Switches ``-dumpstream`` ``--stream-dump=`` ``-dvdangle`` ``--dvd-angle`` ``-endpos`` ``--length`` + ``-fixed-vo`` (removed; always the default) ``-font`` ``--osd-font`` ``-forcedsubsonly`` ``--sub-forced-only`` ``-forceidx`` ``--index`` diff --git a/options/options.c b/options/options.c index 1e7006f4dc..6f23f2c499 100644 --- a/options/options.c +++ b/options/options.c @@ -369,7 +369,6 @@ const m_option_t mp_opts[] = { OPT_SETTINGSLIST("ao-defaults", ao_defs, 0, &ao_obj_list), OPT_STRING("audio-device", audio_device, 0), OPT_STRING("audio-client-name", audio_client_name, 0), - OPT_FLAG("fixed-vo", fixed_vo, CONF_GLOBAL), OPT_FLAG("force-window", force_vo, CONF_GLOBAL), OPT_FLAG("ontop", vo.ontop, M_OPT_FIXED), OPT_FLAG("border", vo.border, M_OPT_FIXED), @@ -654,7 +653,7 @@ const m_option_t mp_opts[] = { OPT_REMOVED("cache-pause-below", "for 'no', use --no-cache-pause"), OPT_REMOVED("no-cache-pause-below", "use --no-cache-pause"), OPT_REMOVED("volstep", "edit input.conf directly instead"), - + OPT_REMOVED("fixed-vo", "--fixed-vo=yes is now the default"), OPT_REPLACED("mkv-subtitle-preroll", "demuxer-mkv-subtitle-preroll"), OPT_REPLACED("dtshd", "ad-spdif-dtshd"), @@ -668,7 +667,6 @@ const struct MPOpts mp_default_opts = { .audio_decoders = "-spdif:*", // never select spdif by default .video_decoders = NULL, .deinterlace = -1, - .fixed_vo = 1, .softvol = SOFTVOL_AUTO, .softvol_max = 200, .mixer_init_volume = -1, diff --git a/options/options.h b/options/options.h index 5d9504902e..7d110faf2a 100644 --- a/options/options.h +++ b/options/options.h @@ -74,7 +74,6 @@ typedef struct MPOpts { struct m_obj_settings *audio_driver_list, *ao_defs; char *audio_device; char *audio_client_name; - int fixed_vo; int force_vo; int softvol; float mixer_init_volume; diff --git a/player/loadfile.c b/player/loadfile.c index bb15068ead..db032d422c 100644 --- a/player/loadfile.c +++ b/player/loadfile.c @@ -282,8 +282,6 @@ static bool timeline_set_part(struct MPContext *mpctx, int i, bool initial) uninit_audio_chain(mpctx); uninit_video_chain(mpctx); uninit_sub_all(mpctx); - if (!mpctx->opts->fixed_vo) - uninit_video_out(mpctx); if (mpctx->ao && !mpctx->opts->gapless_audio) { ao_drain(mpctx->ao); uninit_audio_out(mpctx); @@ -533,7 +531,7 @@ void mp_switch_track_n(struct MPContext *mpctx, int order, enum stream_type type if (order == 0) { if (type == STREAM_VIDEO) { uninit_video_chain(mpctx); - if (!mpctx->opts->fixed_vo || !track) + if (!track) handle_force_window(mpctx, false); } else if (type == STREAM_AUDIO) { clear_audio_output_buffers(mpctx); @@ -1236,8 +1234,6 @@ terminate_playback: uninit_sub_renderer(mpctx); uninit_demuxer(mpctx); uninit_stream(mpctx); - if (!opts->fixed_vo) - uninit_video_out(mpctx); if (!opts->gapless_audio && !mpctx->encode_lavc_ctx) uninit_audio_out(mpctx); diff --git a/player/main.c b/player/main.c index 2dfc9b5dde..854d1ce540 100644 --- a/player/main.c +++ b/player/main.c @@ -446,7 +446,6 @@ int mp_initialize(struct MPContext *mpctx) #endif if (opts->force_vo) { - opts->fixed_vo = 1; struct vo_extra ex = { .input_ctx = mpctx->input, .osd = mpctx->osd, diff --git a/player/video.c b/player/video.c index 17530ab279..29dcb3b066 100644 --- a/player/video.c +++ b/player/video.c @@ -266,7 +266,7 @@ int reinit_video_chain(struct MPContext *mpctx) sh->video->fps); //================== Init VIDEO (codec & libvo) ========================== - if (!opts->fixed_vo || !mpctx->video_out) { + if (!mpctx->video_out) { struct vo_extra ex = { .input_ctx = mpctx->input, .osd = mpctx->osd, -- cgit v1.2.3