summaryrefslogtreecommitdiff
path: root/libavfilter/af_headphone.c
diff options
context:
space:
mode:
authorPaul B Mahol <onemda@gmail.com>2018-04-16 09:31:11 +0200
committerPaul B Mahol <onemda@gmail.com>2018-04-16 09:31:11 +0200
commite1c8bd2389d62b584d68486908b1d6351c027f41 (patch)
tree18de76696eca15ed02ef11bd3cc045e139a04fd8 /libavfilter/af_headphone.c
parent783df2eb59ca2347af89e3eca3aef2ff12779178 (diff)
avfilter/af_headphone: fix type=time with hrir=multich
Signed-off-by: Paul B Mahol <onemda@gmail.com>
Diffstat (limited to 'libavfilter/af_headphone.c')
-rw-r--r--libavfilter/af_headphone.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/libavfilter/af_headphone.c b/libavfilter/af_headphone.c
index a71ed336d8..7910132218 100644
--- a/libavfilter/af_headphone.c
+++ b/libavfilter/af_headphone.c
@@ -567,8 +567,8 @@ static int convert_coeffs(AVFilterContext *ctx, AVFilterLink *inlink)
if (s->type == TIME_DOMAIN) {
offset = idx * FFALIGN(len, 16);
for (j = 0; j < len; j++) {
- data_ir_l[offset + j] = ptr[len * 2 - j * 2 - 2] * gain_lin;
- data_ir_r[offset + j] = ptr[len * 2 - j * 2 - 1] * gain_lin;
+ data_ir_l[offset + j] = ptr[len * N - j * N - N + I ] * gain_lin;
+ data_ir_r[offset + j] = ptr[len * N - j * N - N + I + 1] * gain_lin;
}
} else {
memset(fft_in_l, 0, n_fft * sizeof(*fft_in_l));