FFmpeg
|
#include <float.h>
#include <math.h>
#include "libavutil/mem.h"
#include "libavutil/opt.h"
#include "libavutil/tx.h"
#include "audio.h"
#include "avfilter.h"
#include "filters.h"
#include "internal.h"
#include "window_func.h"
Go to the source code of this file.
Data Structures | |
struct | ChannelSpectralStats |
struct | AudioSpectralStatsContext |
Macros | |
#define | MEASURE_ALL UINT_MAX |
#define | MEASURE_NONE 0 |
#define | MEASURE_MEAN (1 << 0) |
#define | MEASURE_VARIANCE (1 << 1) |
#define | MEASURE_CENTROID (1 << 2) |
#define | MEASURE_SPREAD (1 << 3) |
#define | MEASURE_SKEWNESS (1 << 4) |
#define | MEASURE_KURTOSIS (1 << 5) |
#define | MEASURE_ENTROPY (1 << 6) |
#define | MEASURE_FLATNESS (1 << 7) |
#define | MEASURE_CREST (1 << 8) |
#define | MEASURE_FLUX (1 << 9) |
#define | MEASURE_SLOPE (1 << 10) |
#define | MEASURE_DECREASE (1 << 11) |
#define | MEASURE_ROLLOFF (1 << 12) |
#define | OFFSET(x) offsetof(AudioSpectralStatsContext, x) |
#define | A AV_OPT_FLAG_AUDIO_PARAM|AV_OPT_FLAG_FILTERING_PARAM |
Functions | |
AVFILTER_DEFINE_CLASS (aspectralstats) | |
static int | config_output (AVFilterLink *outlink) |
static void | set_meta (AVDictionary **metadata, int chan, const char *key, const char *fmt, float val) |
static void | set_metadata (AudioSpectralStatsContext *s, AVDictionary **metadata) |
static float | spectral_mean (const float *const spectral, int size, int max_freq) |
static float | sqrf (float a) |
static float | spectral_variance (const float *const spectral, int size, int max_freq, float mean) |
static float | spectral_centroid (const float *const spectral, int size, int max_freq) |
static float | spectral_spread (const float *const spectral, int size, int max_freq, float centroid) |
static float | cbrf (float a) |
static float | spectral_skewness (const float *const spectral, int size, int max_freq, float centroid, float spread) |
static float | spectral_kurtosis (const float *const spectral, int size, int max_freq, float centroid, float spread) |
static float | spectral_entropy (const float *const spectral, int size, int max_freq) |
static float | spectral_flatness (const float *const spectral, int size, int max_freq) |
static float | spectral_crest (const float *const spectral, int size, int max_freq) |
static float | spectral_flux (const float *const spectral, const float *const prev_spectral, int size, int max_freq) |
static float | spectral_slope (const float *const spectral, int size, int max_freq) |
static float | spectral_decrease (const float *const spectral, int size, int max_freq) |
static float | spectral_rolloff (const float *const spectral, int size, int max_freq) |
static int | filter_channel (AVFilterContext *ctx, void *arg, int jobnr, int nb_jobs) |
static int | filter_frame (AVFilterLink *inlink, AVFrame *in) |
static int | activate (AVFilterContext *ctx) |
static av_cold void | uninit (AVFilterContext *ctx) |
Variables | |
static const AVOption | aspectralstats_options [] |
static const AVFilterPad | aspectralstats_outputs [] |
const AVFilter | ff_af_aspectralstats |
#define MEASURE_ALL UINT_MAX |
Definition at line 33 of file af_aspectralstats.c.
#define MEASURE_NONE 0 |
Definition at line 34 of file af_aspectralstats.c.
#define MEASURE_MEAN (1 << 0) |
Definition at line 35 of file af_aspectralstats.c.
#define MEASURE_VARIANCE (1 << 1) |
Definition at line 36 of file af_aspectralstats.c.
#define MEASURE_CENTROID (1 << 2) |
Definition at line 37 of file af_aspectralstats.c.
#define MEASURE_SPREAD (1 << 3) |
Definition at line 38 of file af_aspectralstats.c.
#define MEASURE_SKEWNESS (1 << 4) |
Definition at line 39 of file af_aspectralstats.c.
#define MEASURE_KURTOSIS (1 << 5) |
Definition at line 40 of file af_aspectralstats.c.
#define MEASURE_ENTROPY (1 << 6) |
Definition at line 41 of file af_aspectralstats.c.
#define MEASURE_FLATNESS (1 << 7) |
Definition at line 42 of file af_aspectralstats.c.
#define MEASURE_CREST (1 << 8) |
Definition at line 43 of file af_aspectralstats.c.
#define MEASURE_FLUX (1 << 9) |
Definition at line 44 of file af_aspectralstats.c.
#define MEASURE_SLOPE (1 << 10) |
Definition at line 45 of file af_aspectralstats.c.
#define MEASURE_DECREASE (1 << 11) |
Definition at line 46 of file af_aspectralstats.c.
#define MEASURE_ROLLOFF (1 << 12) |
Definition at line 47 of file af_aspectralstats.c.
#define OFFSET | ( | x | ) | offsetof(AudioSpectralStatsContext, x) |
Definition at line 84 of file af_aspectralstats.c.
Definition at line 85 of file af_aspectralstats.c.
AVFILTER_DEFINE_CLASS | ( | aspectralstats | ) |
|
static |
Definition at line 112 of file af_aspectralstats.c.
|
static |
Definition at line 184 of file af_aspectralstats.c.
Referenced by do_vif(), and set_metadata().
|
static |
Definition at line 198 of file af_aspectralstats.c.
Referenced by filter_frame().
Definition at line 232 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 242 of file af_aspectralstats.c.
Referenced by spectral_flux(), spectral_kurtosis(), spectral_slope(), spectral_spread(), and spectral_variance().
|
static |
Definition at line 247 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 257 of file af_aspectralstats.c.
Referenced by filter_channel().
|
static |
Definition at line 272 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 287 of file af_aspectralstats.c.
Referenced by spectral_skewness().
|
static |
Definition at line 292 of file af_aspectralstats.c.
Referenced by filter_channel().
|
static |
Definition at line 308 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 324 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 338 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 356 of file af_aspectralstats.c.
Referenced by filter_channel().
|
static |
Definition at line 371 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 382 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 401 of file af_aspectralstats.c.
Referenced by filter_channel().
Definition at line 415 of file af_aspectralstats.c.
Referenced by filter_channel().
|
static |
Definition at line 436 of file af_aspectralstats.c.
Referenced by filter_frame().
|
static |
Definition at line 507 of file af_aspectralstats.c.
Referenced by activate().
|
static |
Definition at line 547 of file af_aspectralstats.c.
|
static |
Definition at line 576 of file af_aspectralstats.c.
|
static |
Definition at line 87 of file af_aspectralstats.c.
|
static |
Definition at line 604 of file af_aspectralstats.c.
const AVFilter ff_af_aspectralstats |
Definition at line 612 of file af_aspectralstats.c.