diff options
author | Chris Robinson <[email protected]> | 2016-03-10 01:45:30 -0800 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2016-03-10 01:45:30 -0800 |
commit | da5f75615bf4dee38d456949b30b90921ad713c0 (patch) | |
tree | 5560b99210a638a668794f7b38b7a08c7899ac0b /Alc/effects | |
parent | effb9d1e35ab3679daa6314ffecfc4d71dc4cdf7 (diff) |
Allocate enough reverb panning gains
Diffstat (limited to 'Alc/effects')
-rw-r--r-- | Alc/effects/reverb.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/Alc/effects/reverb.c b/Alc/effects/reverb.c index a1b27876..e68e6e19 100644 --- a/Alc/effects/reverb.c +++ b/Alc/effects/reverb.c @@ -87,7 +87,10 @@ typedef struct ALreverbState { ALuint Offset[4]; // The gain for each output channel based on 3D panning. - ALfloat PanGain[4][MAX_OUTPUT_CHANNELS]; + // NOTE: With HRTF, we may be rendering to the dry buffer and the + // "real" buffer. The dry buffer may be using all 8 output channels, so + // we need two extra for the real stereo output. + ALfloat PanGain[4][MAX_OUTPUT_CHANNELS+2]; } Early; // Decorrelator delay line. @@ -125,7 +128,8 @@ typedef struct ALreverbState { ALfloat LpSample[4]; // The gain for each output channel based on 3D panning. - ALfloat PanGain[4][MAX_OUTPUT_CHANNELS]; + // NOTE: Add two in case of HRTF (see note about early pan). + ALfloat PanGain[4][MAX_OUTPUT_CHANNELS+2]; } Late; struct { |