mirror of https://git.ffmpeg.org/ffmpeg.git
avfilter/af_sofalizer: set delays when interpolation is disabled
This commit is contained in:
parent
c4a05ae65c
commit
ee64b64c02
|
@ -627,6 +627,13 @@ static int getfilter_float(AVFilterContext *ctx, float x, float y, float z,
|
|||
nearest, neighbors,
|
||||
s->sofa.fir, delays);
|
||||
} else {
|
||||
if (s->sofa.hrtf->DataDelay.elements > s->sofa.hrtf->R) {
|
||||
delays[0] = s->sofa.hrtf->DataDelay.values[nearest * s->sofa.hrtf->R];
|
||||
delays[1] = s->sofa.hrtf->DataDelay.values[nearest * s->sofa.hrtf->R + 1];
|
||||
} else {
|
||||
delays[0] = s->sofa.hrtf->DataDelay.values[0];
|
||||
delays[1] = s->sofa.hrtf->DataDelay.values[1];
|
||||
}
|
||||
res = s->sofa.hrtf->DataIR.values + nearest * s->sofa.hrtf->N * s->sofa.hrtf->R;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue