[FFmpeg-devel] [PATCH 2/2] avfilter: add flanger filter
Clément Bœsch
u at pkh.me
Tue Jul 1 19:25:19 CEST 2014
On Tue, Jul 01, 2014 at 08:41:00AM +0000, Paul B Mahol wrote:
> Signed-off-by: Paul B Mahol <onemda at gmail.com>
> ---
> libavfilter/Makefile | 1 +
> libavfilter/af_flanger.c | 239 +++++++++++++++++++++++++++++++++++++++++++++++
> libavfilter/allfilters.c | 1 +
> 3 files changed, 241 insertions(+)
> create mode 100644 libavfilter/af_flanger.c
>
[...]
> +static int config_input(AVFilterLink *inlink)
> +{
> + AVFilterContext *ctx = inlink->dst;
> + FlangerContext *s = ctx->priv;
> +
> + s->max_samples = (s->delay_min + s->delay_depth) * inlink->sample_rate + 2.5;
> + s->lfo_length = inlink->sample_rate / s->speed;
> + s->delay_last = av_calloc(inlink->channels, sizeof(*s->delay_last));
> + s->lfo = av_calloc(s->lfo_length, sizeof(*s->lfo));
> + if (!s->lfo || !s->delay_last)
> + return AVERROR(ENOMEM);
> +
> + ff_generate_wave_table(s->wave_shape, AV_SAMPLE_FMT_FLT, s->lfo, s->lfo_length,
This filter seems to support only double, why request FMT_FLT here?
(ff_generate_wave_table() seems to support DBL)
[...]
--
Clément B.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 490 bytes
Desc: not available
URL: <https://ffmpeg.org/pipermail/ffmpeg-devel/attachments/20140701/66cbb643/attachment.asc>
More information about the ffmpeg-devel
mailing list