[FFmpeg-cvslog] lavfi/anullsrc: switch to an AVOptions-based system.

Clément Bœsch git at videolan.org
Thu Apr 11 15:22:29 CEST 2013


ffmpeg | branch: master | Clément Bœsch <ubitux at gmail.com> | Thu Apr 11 15:21:40 2013 +0200| [1c0feee05930924a886584aab96c3669b79818b3] | committer: Clément Bœsch

lavfi/anullsrc: switch to an AVOptions-based system.

> http://git.videolan.org/gitweb.cgi/ffmpeg.git/?a=commit;h=1c0feee05930924a886584aab96c3669b79818b3
---

 doc/filters.texi            |   11 ++++-------
 libavfilter/asrc_anullsrc.c |    6 ------
 libavfilter/avfilter.c      |    1 -
 3 files changed, 4 insertions(+), 14 deletions(-)

diff --git a/doc/filters.texi b/doc/filters.texi
index 55f2062..3b20c80 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -1596,16 +1596,10 @@ as a template and to be employed in analysis / debugging tools, or as
 the source for filters which ignore the input data (for example the sox
 synth filter).
 
-It 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
 
- at item sample_rate, s
-Specify the sample rate, and defaults to 44100.
-
 @item channel_layout, cl
 
 Specify the channel layout, and can be either an integer or a string
@@ -1616,6 +1610,9 @@ Check the channel_layout_map definition in
 @file{libavutil/channel_layout.c} for the mapping between strings and
 channel layout values.
 
+ at item sample_rate, r
+Specify the sample rate, and defaults to 44100.
+
 @item nb_samples, n
 Set the number of samples per requested frames.
 
diff --git a/libavfilter/asrc_anullsrc.c b/libavfilter/asrc_anullsrc.c
index 84260c3..fe0ec91 100644
--- a/libavfilter/asrc_anullsrc.c
+++ b/libavfilter/asrc_anullsrc.c
@@ -64,12 +64,6 @@ static int init(AVFilterContext *ctx, const char *args)
     ANullContext *null = ctx->priv;
     int ret;
 
-    null->class = &anullsrc_class;
-    av_opt_set_defaults(null);
-
-    if ((ret = av_set_options_string(null, args, "=", ":")) < 0)
-        return ret;
-
     if ((ret = ff_parse_sample_rate(&null->sample_rate,
                                      null->sample_rate_str, ctx)) < 0)
         return ret;
diff --git a/libavfilter/avfilter.c b/libavfilter/avfilter.c
index 18753b3..cce7bc6 100644
--- a/libavfilter/avfilter.c
+++ b/libavfilter/avfilter.c
@@ -676,7 +676,6 @@ static const char *const filters_left_to_update[] = {
     "aconvert",
     "aevalsrc",
     "amerge",
-    "anullsrc",
     "aresample",
     "asetnsamples",
     "atempo",



More information about the ffmpeg-cvslog mailing list