Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in / Register
Toggle navigation
F
ffmpeg.wasm-core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Linshizhi
ffmpeg.wasm-core
Commits
72280d1c
Commit
72280d1c
authored
Dec 31, 2015
by
Paul B Mahol
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
avfilter: add showspectrumpic filter
Signed-off-by:
Paul B Mahol
<
onemda@gmail.com
>
parent
7f7a9dd7
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
370 additions
and
46 deletions
+370
-46
Changelog
Changelog
+1
-0
filters.texi
doc/filters.texi
+106
-0
Makefile
libavfilter/Makefile
+1
-0
allfilters.c
libavfilter/allfilters.c
+1
-0
avf_showspectrum.c
libavfilter/avf_showspectrum.c
+260
-45
version.h
libavfilter/version.h
+1
-1
No files found.
Changelog
View file @
72280d1c
...
...
@@ -50,6 +50,7 @@ version <next>:
- VAAPI VP9 hwaccel
- audio high-order multiband parametric equalizer
- automatic bitstream filtering
- showspectrumpic filter
version 2.8:
...
...
doc/filters.texi
View file @
72280d1c
...
...
@@ -14704,6 +14704,112 @@ ffplay -f lavfi 'amovie=input.mp3, asplit [a][out1];
@end example
@end itemize
@section showspectrumpic
Convert input audio to a single video frame, representing the audio frequency
spectrum.
The filter accepts the following options:
@table @option
@item size, s
Specify the video size for the output. For the syntax of this option, check the
@ref{video size syntax,,"Video size" section in the ffmpeg-utils manual,ffmpeg-utils}.
Default value is @code{4096x2048}.
@item mode
Specify display mode.
It accepts the following values:
@table @samp
@item combined
all channels are displayed in the same row
@item separate
all channels are displayed in separate rows
@end table
Default value is @samp{combined}.
@item color
Specify display color mode.
It accepts the following values:
@table @samp
@item channel
each channel is displayed in a separate color
@item intensity
each channel is displayed using the same color scheme
@item rainbow
each channel is displayed using the rainbow color scheme
@item moreland
each channel is displayed using the moreland color scheme
@item nebulae
each channel is displayed using the nebulae color scheme
@item fire
each channel is displayed using the fire color scheme
@end table
Default value is @samp{intensity}.
@item scale
Specify scale used for calculating intensity color values.
It accepts the following values:
@table @samp
@item lin
linear
@item sqrt
square root, default
@item cbrt
cubic root
@item log
logarithmic
@end table
Default value is @samp{log}.
@item saturation
Set saturation modifier for displayed colors. Negative values provide
alternative color scheme. @code{0} is no saturation at all.
Saturation must be in [-10.0, 10.0] range.
Default value is @code{1}.
@item win_func
Set window function.
It accepts the following values:
@table @samp
@item rect
@item bartlett
@item hann
@item hanning
@item hamming
@item blackman
@item welch
@item flattop
@item bharris
@item bnuttall
@item bhann
@item sine
@item nuttall
@item lanczos
@item gauss
@end table
Default value is @code{hann}.
@item orientation
Set orientation of time vs frequency axis. Can be @code{vertical} or
@code{horizontal}. Default is @code{vertical}.
@end table
@subsection Examples
@itemize
@item
Extract an audio spectrogram of a whole audio track
in a 1024x1024 picture using @command{ffmpeg}:
@example
ffmpeg -i audio.flac -lavfi showspectrumpic=s=1024x1024 spectrogram.png
@end example
@end itemize
@section showvolume
Convert input audio volume to a video output.
...
...
libavfilter/Makefile
View file @
72280d1c
...
...
@@ -286,6 +286,7 @@ OBJS-$(CONFIG_CONCAT_FILTER) += avf_concat.o
OBJS-$(CONFIG_SHOWCQT_FILTER)
+=
avf_showcqt.o
lswsutils.o
lavfutils.o
OBJS-$(CONFIG_SHOWFREQS_FILTER)
+=
avf_showfreqs.o
window_func.o
OBJS-$(CONFIG_SHOWSPECTRUM_FILTER)
+=
avf_showspectrum.o
window_func.o
OBJS-$(CONFIG_SHOWSPECTRUMPIC_FILTER)
+=
avf_showspectrum.o
window_func.o
OBJS-$(CONFIG_SHOWVOLUME_FILTER)
+=
avf_showvolume.o
OBJS-$(CONFIG_SHOWWAVES_FILTER)
+=
avf_showwaves.o
OBJS-$(CONFIG_SHOWWAVESPIC_FILTER)
+=
avf_showwaves.o
...
...
libavfilter/allfilters.c
View file @
72280d1c
...
...
@@ -306,6 +306,7 @@ void avfilter_register_all(void)
REGISTER_FILTER
(
SHOWCQT
,
showcqt
,
avf
);
REGISTER_FILTER
(
SHOWFREQS
,
showfreqs
,
avf
);
REGISTER_FILTER
(
SHOWSPECTRUM
,
showspectrum
,
avf
);
REGISTER_FILTER
(
SHOWSPECTRUMPIC
,
showspectrumpic
,
avf
);
REGISTER_FILTER
(
SHOWVOLUME
,
showvolume
,
avf
);
REGISTER_FILTER
(
SHOWWAVES
,
showwaves
,
avf
);
REGISTER_FILTER
(
SHOWWAVESPIC
,
showwavespic
,
avf
);
...
...
libavfilter/avf_showspectrum.c
View file @
72280d1c
This diff is collapsed.
Click to expand it.
libavfilter/version.h
View file @
72280d1c
...
...
@@ -30,7 +30,7 @@
#include "libavutil/version.h"
#define LIBAVFILTER_VERSION_MAJOR 6
#define LIBAVFILTER_VERSION_MINOR 2
2
#define LIBAVFILTER_VERSION_MINOR 2
3
#define LIBAVFILTER_VERSION_MICRO 100
#define LIBAVFILTER_VERSION_INT AV_VERSION_INT(LIBAVFILTER_VERSION_MAJOR, \
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment