aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/mixer.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2017-01-17 16:49:26 -0800
committerChris Robinson <[email protected]>2017-01-17 16:49:26 -0800
commitba0944af9ba8d851bc5b6ad99f314bbdac269716 (patch)
tree3031abd32f417c78b52476fccac0aa0ac6611996 /Alc/mixer.c
parentbfb7a6e4c85838bf2f6ed28fba452c55ad50c566 (diff)
Pass the left and right buffers to the hrtf mixers directly
Diffstat (limited to 'Alc/mixer.c')
-rw-r--r--Alc/mixer.c10
1 files changed, 6 insertions, 4 deletions
diff --git a/Alc/mixer.c b/Alc/mixer.c
index e759482e..2d804b1f 100644
--- a/Alc/mixer.c
+++ b/Alc/mixer.c
@@ -589,7 +589,7 @@ ALvoid MixSource(ALvoice *voice, ALsource *Source, ALCdevice *Device, ALuint Sam
{
ALfloat delta = 1.0f / (ALfloat)Counter;
ALfloat coeffdiff;
- ALsizei delaydiff;
+ ALint delaydiff;
for(j = 0;j < IrSize;j++)
{
coeffdiff = parms->Hrtf.Target.Coeffs[j][0] - parms->Hrtf.Current.Coeffs[j][0];
@@ -609,9 +609,11 @@ ALvoid MixSource(ALvoice *voice, ALsource *Source, ALCdevice *Device, ALuint Sam
ridx = GetChannelIdxByName(Device->RealOut, FrontRight);
assert(lidx != -1 && ridx != -1);
- MixHrtfSamples(voice->DirectOut.Buffer, lidx, ridx, samples, Counter,
- voice->Offset, OutPos, IrSize, &hrtfparams,
- &parms->Hrtf.State, DstBufferSize);
+ MixHrtfSamples(
+ voice->DirectOut.Buffer[lidx], voice->DirectOut.Buffer[ridx],
+ samples, Counter, voice->Offset, OutPos, IrSize, &hrtfparams,
+ &parms->Hrtf.State, DstBufferSize
+ );
}
}