aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMichael Niedermayer <michaelni@gmx.at>2013-04-11 00:37:21 +0200
committerMichael Niedermayer <michaelni@gmx.at>2013-04-11 00:37:32 +0200
commitb4ffc35e76fc7106902323831248393f33f94c55 (patch)
tree1dadb62aba9a96d54c9f50be08558006e010d23f
parenta4e0defa75b6f766aa31d80c55688d036b5fd87b (diff)
parent4ecee69b20a7ee60fba6cb53ff45d95a015df05b (diff)
downloadffmpeg-b4ffc35e76fc7106902323831248393f33f94c55.tar.gz
Merge remote-tracking branch 'ubitux/shorthand-cleanup'
* ubitux/shorthand-cleanup: lavfi/mptestsrc: switch to an AVOptions-based system. lavfi/mandelbrot: switch to an AVOptions-based system. lavfi/life: switch to an AVOptions-based system. lavfi/cellauto: switch to an AVOptions-based system. Merged-by: Michael Niedermayer <michaelni@gmx.at>
-rw-r--r--doc/filters.texi15
-rw-r--r--libavfilter/avfilter.c4
-rw-r--r--libavfilter/vsrc_cellauto.c6
-rw-r--r--libavfilter/vsrc_life.c6
-rw-r--r--libavfilter/vsrc_mandelbrot.c6
-rw-r--r--libavfilter/vsrc_mptestsrc.c6
6 files changed, 8 insertions, 35 deletions
diff --git a/doc/filters.texi b/doc/filters.texi
index 96f15c5cc6..07cfeaae28 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -5806,9 +5806,7 @@ At each new frame a new row in the video is filled with the result of
the cellular automaton next generation. The behavior when the whole
frame is filled is defined by the @option{scroll} option.
-This source accepts a list of options in the form of
-@var{key}=@var{value} pairs separated by ":". A description of the
-accepted options follows.
+This source accepts the following options:
@table @option
@item filename, f
@@ -5914,9 +5912,7 @@ cellauto=p='@@@@ @@ @@@@':s=100x400:full=0:rule=18
Generate a Mandelbrot set fractal, and progressively zoom towards the
point specified with @var{start_x} and @var{start_y}.
-This source accepts a list of options in the form of
-@var{key}=@var{value} pairs separated by ":". A description of the
-accepted options follows.
+This source accepts the following options:
@table @option
@@ -5989,8 +5985,7 @@ Generate various test patterns, as generated by the MPlayer test filter.
The size of the generated video is fixed, and is 256x256.
This source is useful in particular for testing encoding features.
-This source accepts an optional sequence of @var{key}=@var{value} pairs,
-separated by ":". The description of the accepted options follows.
+This source accepts the following options:
@table @option
@@ -6090,9 +6085,7 @@ which specifies the number of neighbor alive cells which will make a
cell stay alive or born. The @option{rule} option allows to specify
the rule to adopt.
-This source accepts a list of options in the form of
-@var{key}=@var{value} pairs separated by ":". A description of the
-accepted options follows.
+This source accepts the following options:
@table @option
@item filename, f
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index 226008ee61..935c6fa287 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -660,6 +660,7 @@ int avfilter_init_filter(AVFilterContext *filter, const char *args, void *opaque
!strcmp(filter->filter->name, "ass") ||
!strcmp(filter->filter->name, "blackframe") ||
!strcmp(filter->filter->name, "boxblur" ) ||
+ !strcmp(filter->filter->name, "cellauto") ||
!strcmp(filter->filter->name, "colormatrix") ||
!strcmp(filter->filter->name, "crop" ) ||
!strcmp(filter->filter->name, "cropdetect") ||
@@ -680,9 +681,12 @@ int avfilter_init_filter(AVFilterContext *filter, const char *args, void *opaque
!strcmp(filter->filter->name, "gradfun" ) ||
!strcmp(filter->filter->name, "hqdn3d" ) ||
!strcmp(filter->filter->name, "ocv" ) ||
+ !strcmp(filter->filter->name, "life" ) ||
!strcmp(filter->filter->name, "lut" ) ||
!strcmp(filter->filter->name, "lutyuv" ) ||
!strcmp(filter->filter->name, "lutrgb" ) ||
+ !strcmp(filter->filter->name, "mandelbrot" ) ||
+ !strcmp(filter->filter->name, "mptestsrc" ) ||
!strcmp(filter->filter->name, "negate" ) ||
!strcmp(filter->filter->name, "overlay" ) ||
!strcmp(filter->filter->name, "pad" ) ||
diff --git a/libavfilter/vsrc_cellauto.c b/libavfilter/vsrc_cellauto.c
index a48f04c3e1..3a4917a026 100644
--- a/libavfilter/vsrc_cellauto.c
+++ b/libavfilter/vsrc_cellauto.c
@@ -164,12 +164,6 @@ static int init(AVFilterContext *ctx, const char *args)
CellAutoContext *cellauto = ctx->priv;
int ret;
- cellauto->class = &cellauto_class;
- av_opt_set_defaults(cellauto);
-
- if ((ret = av_set_options_string(cellauto, args, "=", ":")) < 0)
- return ret;
-
if (!cellauto->w && !cellauto->filename && !cellauto->pattern)
av_opt_set(cellauto, "size", "320x518", 0);
diff --git a/libavfilter/vsrc_life.c b/libavfilter/vsrc_life.c
index d7ed40bf53..2d0b2f524a 100644
--- a/libavfilter/vsrc_life.c
+++ b/libavfilter/vsrc_life.c
@@ -225,12 +225,6 @@ static int init(AVFilterContext *ctx, const char *args)
LifeContext *life = ctx->priv;
int ret;
- life->class = &life_class;
- av_opt_set_defaults(life);
-
- if ((ret = av_set_options_string(life, args, "=", ":")) < 0)
- return ret;
-
if (!life->w && !life->filename)
av_opt_set(life, "size", "320x240", 0);
diff --git a/libavfilter/vsrc_mandelbrot.c b/libavfilter/vsrc_mandelbrot.c
index c91494b11d..d27215c2c3 100644
--- a/libavfilter/vsrc_mandelbrot.c
+++ b/libavfilter/vsrc_mandelbrot.c
@@ -122,13 +122,7 @@ AVFILTER_DEFINE_CLASS(mandelbrot);
static av_cold int init(AVFilterContext *ctx, const char *args)
{
MBContext *mb = ctx->priv;
- int err;
- mb->class = &mandelbrot_class;
- av_opt_set_defaults(mb);
-
- if ((err = (av_set_options_string(mb, args, "=", ":"))) < 0)
- return err;
mb->bailout *= mb->bailout;
mb->start_scale /=mb->h;
diff --git a/libavfilter/vsrc_mptestsrc.c b/libavfilter/vsrc_mptestsrc.c
index 9f1c46f849..e2341081ce 100644
--- a/libavfilter/vsrc_mptestsrc.c
+++ b/libavfilter/vsrc_mptestsrc.c
@@ -262,12 +262,6 @@ static av_cold int init(AVFilterContext *ctx, const char *args)
int64_t duration = -1;
int ret;
- test->class = &mptestsrc_class;
- av_opt_set_defaults(test);
-
- if ((ret = (av_set_options_string(test, args, "=", ":"))) < 0)
- return ret;
-
if ((test->duration) && (ret = av_parse_time(&duration, test->duration, 1)) < 0) {
av_log(ctx, AV_LOG_ERROR, "Invalid duration: '%s'\n", test->duration);
return ret;