[FFmpeg-cvslog] avfilter/avf_showwaves: Add draw mode also to showwavespic filter

Martin Vobruba git at videolan.org
Mon Apr 29 21:39:24 EEST 2019


ffmpeg | branch: master | Martin Vobruba <vobruba.martin at gmail.com> | Fri Apr 26 08:17:11 2019 +0200| [093a504414ef7781123f0db49326b0059e32a818] | committer: Paul B Mahol

avfilter/avf_showwaves: Add draw mode also to showwavespic filter

See commit a8c2d375ca68b7f001564ced14d8ac0757f53a29

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

 doc/filters.texi            | 14 ++++++++++++++
 libavfilter/avf_showwaves.c |  3 +++
 2 files changed, 17 insertions(+)

diff --git a/doc/filters.texi b/doc/filters.texi
index 7cc3937b40..cd82869849 100644
--- a/doc/filters.texi
+++ b/doc/filters.texi
@@ -22704,6 +22704,20 @@ Cubic root.
 @end table
 
 Default is linear.
+
+ at item draw
+Set the draw mode.
+
+Available values are:
+ at table @samp
+ at item scale
+Scale pixel values for each drawn sample.
+
+ at item full
+Draw every sample directly.
+ at end table
+
+Default value is @code{scale}.
 @end table
 
 @subsection Examples
diff --git a/libavfilter/avf_showwaves.c b/libavfilter/avf_showwaves.c
index 0e683cf42d..a0d2b25d55 100644
--- a/libavfilter/avf_showwaves.c
+++ b/libavfilter/avf_showwaves.c
@@ -765,6 +765,9 @@ static const AVOption showwavespic_options[] = {
         { "log", "logarithmic",    0, AV_OPT_TYPE_CONST, {.i64=SCALE_LOG}, .flags=FLAGS, .unit="scale"},
         { "sqrt", "square root",   0, AV_OPT_TYPE_CONST, {.i64=SCALE_SQRT}, .flags=FLAGS, .unit="scale"},
         { "cbrt", "cubic root",    0, AV_OPT_TYPE_CONST, {.i64=SCALE_CBRT}, .flags=FLAGS, .unit="scale"},
+    { "draw", "set draw mode", OFFSET(draw_mode), AV_OPT_TYPE_INT, {.i64 = DRAW_SCALE}, 0, DRAW_NB-1, FLAGS, .unit="draw" },
+        { "scale", "scale pixel values for each drawn sample", 0, AV_OPT_TYPE_CONST, {.i64=DRAW_SCALE}, .flags=FLAGS, .unit="draw"},
+        { "full",  "draw every pixel for sample directly",     0, AV_OPT_TYPE_CONST, {.i64=DRAW_FULL},  .flags=FLAGS, .unit="draw"},
     { NULL }
 };
 



More information about the ffmpeg-cvslog mailing list