aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2014-11-21 14:35:19 -0800
committerChris Robinson <[email protected]>2014-11-21 14:35:19 -0800
commitccba33169bfcdc0dd64c6e9f854a34e05cdb20da (patch)
tree0c28e64aaa82b957edf46db62db7d57a85fb7b81
parent4ad6905c135d6964e57fe48fb7f93e579d028887 (diff)
Initialize panning after setting up HRTF
-rw-r--r--Alc/ALc.c10
1 files changed, 5 insertions, 5 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index 915a03ef..f83a884c 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -1956,10 +1956,6 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
DevFmtTypeString(device->FmtType), device->Frequency,
device->UpdateSize, device->NumUpdates);
- aluInitPanning(device);
-
- V(device->Synth,update)(device);
-
device->Hrtf = NULL;
if((device->Flags&DEVICE_HRTF_REQUEST))
{
@@ -1996,14 +1992,18 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
WARN("NEON performs best with multiple of 4 update sizes (%u)\n", device->UpdateSize);
}
+ aluInitPanning(device);
+
al_free(device->DryBuffer);
device->DryBuffer = al_calloc(16, sizeof(device->DryBuffer[0]) * device->NumChannels);
if(!device->DryBuffer)
{
- ERR("Failed to allocate "SZFMT"-byte mix buffer\n", sizeof(device->DryBuffer[0]) * device->NumChannels);
+ ERR("Failed to allocate "SZFMT" bytes for mix buffer\n", sizeof(device->DryBuffer[0]) * device->NumChannels);
return ALC_INVALID_DEVICE;
}
+ V(device->Synth,update)(device);
+
SetMixerFPUMode(&oldMode);
V0(device->Backend,lock)();
context = ATOMIC_LOAD(&device->ContextList);