86 for (
i = 0;
i <
ctx->nb_inputs && nb_samples > 0;
i++) {
97 if (
s->frames[0] &&
s->frames[1]) {
102 plane_samples =
FFALIGN(
s->frames[0]->nb_samples,
s->samples_align);
104 plane_samples =
FFALIGN(
s->frames[0]->nb_samples *
s->channels,
s->samples_align);
110 out->pts =
s->frames[0]->pts;
113 for (
i = 0;
i <
s->planes;
i++) {
114 s->fdsp->vector_fmul((
float *)
out->extended_data[
i],
115 (
const float *)
s->frames[0]->extended_data[
i],
116 (
const float *)
s->frames[1]->extended_data[
i],
120 for (
i = 0;
i <
s->planes;
i++) {
121 s->fdsp->vector_dmul((
double *)
out->extended_data[
i],
122 (
const double *)
s->frames[0]->extended_data[
i],
123 (
const double *)
s->frames[1]->extended_data[
i],
138 for (
i = 0;
i < 2;
i++) {
147 for (
i = 0;
i < 2;
i++) {
165 s->samples_align = 16;
static enum AVSampleFormat sample_fmts[]
static int query_formats(AVFilterContext *ctx)
static const AVFilterPad inputs[]
static const AVFilterPad outputs[]
static int activate(AVFilterContext *ctx)
static av_cold int init(AVFilterContext *ctx)
static av_cold void uninit(AVFilterContext *ctx)
static int config_output(AVFilterLink *outlink)
AVFrame * ff_get_audio_buffer(AVFilterLink *link, int nb_samples)
Request an audio samples buffer with a specific set of permissions.
simple assert() macros that are a bit more flexible than ISO C assert().
int ff_inlink_acknowledge_status(AVFilterLink *link, int *rstatus, int64_t *rpts)
Test and acknowledge the change of status on the link.
int ff_inlink_check_available_samples(AVFilterLink *link, unsigned min)
Test if enough samples are available on the link.
int ff_filter_frame(AVFilterLink *link, AVFrame *frame)
Send a frame of data to the next filter.
int ff_inlink_consume_samples(AVFilterLink *link, unsigned min, unsigned max, AVFrame **rframe)
Take samples from the link's FIFO and update the link's stats.
int ff_inlink_queued_samples(AVFilterLink *link)
void ff_inlink_request_frame(AVFilterLink *link)
Mark that a frame is wanted on the link.
Main libavfilter public API header.
audio channel layout utility functions
common internal and external API header
static void ff_outlink_set_status(AVFilterLink *link, int status, int64_t pts)
Set the status field of a link from the source filter.
#define FF_FILTER_FORWARD_STATUS_BACK_ALL(outlink, filter)
Forward the status on an output link to all input links.
static int ff_outlink_frame_wanted(AVFilterLink *link)
Test if a frame is wanted on an output link.
void av_frame_free(AVFrame **frame)
Free the frame and any dynamically allocated objects in it, e.g.
int av_sample_fmt_is_planar(enum AVSampleFormat sample_fmt)
Check if the sample format is planar.
enum AVSampleFormat av_get_packed_sample_fmt(enum AVSampleFormat sample_fmt)
Get the packed alternative form of the given sample format.
AVSampleFormat
Audio sample formats.
@ AV_SAMPLE_FMT_FLTP
float, planar
@ AV_SAMPLE_FMT_DBLP
double, planar
@ AV_SAMPLE_FMT_DBL
double
av_cold AVFloatDSPContext * avpriv_float_dsp_alloc(int bit_exact)
Allocate a float DSP context.
common internal API header
#define NULL_IF_CONFIG_SMALL(x)
Return NULL if CONFIG_SMALL is true, otherwise the argument without modification.
enum MovChannelLayoutTag * layouts
Describe the class of an AVClass context structure.
A list of supported channel layouts.
A link between two filters.
int channels
Number of channels.
AVFilterContext * src
source filter
int format
agreed upon media format
A filter pad used for either input or output.
const char * name
Pad name.
const char * name
Filter name.
This structure describes decoded (raw) audio or video data.