diff options
author | Paul B Mahol <onemda@gmail.com> | 2018-05-30 12:30:24 +0200 |
---|---|---|
committer | Paul B Mahol <onemda@gmail.com> | 2018-05-30 12:30:24 +0200 |
commit | d0e740b8fb30f02914594d00eb311a32442a63f8 (patch) | |
tree | bd4667da9926addbf267ac58a3681c626a26fa64 /libavfilter/af_afir.c | |
parent | ea0010bf9cd2be63ab0c174abd3cac754af9ee40 (diff) | |
download | ffmpeg-d0e740b8fb30f02914594d00eb311a32442a63f8.tar.gz |
avfilter/af_afir: fix picking of IR channel
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavfilter/af_afir.c')
-rw-r--r-- | libavfilter/af_afir.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libavfilter/af_afir.c b/libavfilter/af_afir.c index cdc7d29e7e..75de14729d 100644 --- a/libavfilter/af_afir.c +++ b/libavfilter/af_afir.c @@ -230,7 +230,7 @@ static void draw_response(AVFilterContext *ctx, AVFrame *out) if (!mag || !phase) goto end; - channel = av_clip(s->ir_channel, 0, s->in[1]->channels); + channel = av_clip(s->ir_channel, 0, s->in[1]->channels - 1); for (i = 0; i < s->w; i++) { const float *src = (const float *)s->in[1]->extended_data[channel]; double w = i * M_PI / (s->w - 1); |