diff options
author | Anton Khirnov <anton@khirnov.net> | 2011-06-18 09:49:24 +0200 |
---|---|---|
committer | Anton Khirnov <anton@khirnov.net> | 2011-07-08 19:58:19 +0200 |
commit | f5302e5dcf6572e9424d51d152bffc570cd75ce6 (patch) | |
tree | 1c4d71474f5e888213d15b7a329d78b84b61b5f7 | |
parent | d31e3f7ccc5d1e198b3a582f4413ce7342928d8c (diff) | |
download | ffmpeg-f5302e5dcf6572e9424d51d152bffc570cd75ce6.tar.gz |
ffmpeg: deprecate loop_input and loop_output options
They were replaced by (de)muxer private options.
-rw-r--r-- | doc/ffmpeg.texi | 2 | ||||
-rw-r--r-- | ffmpeg.c | 14 | ||||
-rw-r--r-- | tests/ref/lavf/gif | 4 | ||||
-rw-r--r-- | tests/ref/seek/lavf_gif | 2 |
4 files changed, 15 insertions, 7 deletions
diff --git a/doc/ffmpeg.texi b/doc/ffmpeg.texi index cabf395582..6e7fd1390d 100644 --- a/doc/ffmpeg.texi +++ b/doc/ffmpeg.texi @@ -731,9 +731,11 @@ Read input at native frame rate. Mainly used to simulate a grab device. @item -loop_input Loop over the input stream. Currently it works only for image streams. This option is used for automatic FFserver testing. +This option is deprecated, use -loop. @item -loop_output @var{number_of_times} Repeatedly loop output for formats that support looping such as animated GIF (0 will loop the output infinitely). +This option is deprecated, use -loop. @item -threads @var{count} Thread count. @item -vsync @var{parameter} @@ -3247,7 +3247,10 @@ static int opt_input_file(const char *opt, const char *filename) opt_programid=0; } - ic->loop_input = loop_input; + if (loop_input) { + av_log(NULL, AV_LOG_WARNING, "-loop_input is deprecated, use -loop 1\n"); + ic->loop_input = loop_input; + } /* Set AVCodecContext options so they will be seen by av_find_stream_info() */ for (i = 0; i < ic->nb_streams; i++) { @@ -3897,7 +3900,10 @@ static void opt_output_file(const char *filename) oc->preload= (int)(mux_preload*AV_TIME_BASE); oc->max_delay= (int)(mux_max_delay*AV_TIME_BASE); - oc->loop_output = loop_output; + if (loop_output >= 0) { + av_log(NULL, AV_LOG_WARNING, "-loop_output is deprecated, use -loop\n"); + oc->loop_output = loop_output; + } oc->flags |= AVFMT_FLAG_NONBLOCK; frame_rate = (AVRational){0, 0}; @@ -4309,8 +4315,8 @@ static const OptionDef options[] = { { "hex", OPT_BOOL | OPT_EXPERT, {(void*)&do_hex_dump}, "when dumping packets, also dump the payload" }, { "re", OPT_BOOL | OPT_EXPERT, {(void*)&rate_emu}, "read input at native frame rate", "" }, - { "loop_input", OPT_BOOL | OPT_EXPERT, {(void*)&loop_input}, "loop (current only works with images)" }, - { "loop_output", HAS_ARG | OPT_INT | OPT_EXPERT, {(void*)&loop_output}, "number of times to loop output in formats that support looping (0 loops forever)", "" }, + { "loop_input", OPT_BOOL | OPT_EXPERT, {(void*)&loop_input}, "deprecated, use -loop" }, + { "loop_output", HAS_ARG | OPT_INT | OPT_EXPERT, {(void*)&loop_output}, "deprecated, use -loop", "" }, { "v", HAS_ARG, {(void*)opt_verbose}, "set ffmpeg verbosity level", "number" }, { "target", HAS_ARG, {(void*)opt_target}, "specify target file type (\"vcd\", \"svcd\", \"dvd\", \"dv\", \"dv50\", \"pal-vcd\", \"ntsc-svcd\", ...)", "type" }, { "threads", HAS_ARG | OPT_EXPERT, {(void*)opt_thread_count}, "thread count", "count" }, diff --git a/tests/ref/lavf/gif b/tests/ref/lavf/gif index fa55d0e66e..4a4ebfb9dc 100644 --- a/tests/ref/lavf/gif +++ b/tests/ref/lavf/gif @@ -1,3 +1,3 @@ -98968ceb210ab260a6a7af36767b94d3 *./tests/data/lavf/lavf.gif -2906382 ./tests/data/lavf/lavf.gif +e6089fd4ef3b9df44090ab3650bdd810 *./tests/data/lavf/lavf.gif +2906401 ./tests/data/lavf/lavf.gif ./tests/data/lavf/lavf.gif CRC=0xe5605ff6 diff --git a/tests/ref/seek/lavf_gif b/tests/ref/seek/lavf_gif index 5da803da42..883f18761e 100644 --- a/tests/ref/seek/lavf_gif +++ b/tests/ref/seek/lavf_gif @@ -1,4 +1,4 @@ -ret: 0 st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos: -1 size:2906382 +ret: 0 st: 0 flags:1 dts: 0.000000 pts: 0.000000 pos: -1 size:2906401 ret:-EINVAL st:-1 flags:0 ts:-1.000000 ret:-EINVAL st:-1 flags:1 ts: 1.894167 ret:-EINVAL st: 0 flags:0 ts: 0.800000 |