aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALc.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2015-09-20 04:10:21 -0700
committerChris Robinson <[email protected]>2015-09-20 08:28:34 -0700
commit5f5eebc4df536daef7f68d02f7a0c751c8dc0f79 (patch)
treed86069c47e3b05437b97601102a2104a96ac7b6e /Alc/ALc.c
parent46bbf95bae605ac8be1ca163e337b33928627960 (diff)
Allow the hrtf_tables option to be device-specific
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r--Alc/ALc.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index d43b587c..6c963bf3 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -1924,7 +1924,7 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
if(hrtf_userreq == Hrtf_Enable || (hrtf_userreq != Hrtf_Disable && hrtf_appreq == Hrtf_Enable))
{
- if(FindHrtfFormat(&device->FmtChans, &device->Frequency))
+ if(FindHrtfFormat(device->DeviceName, &device->FmtChans, &device->Frequency))
device->Flags |= DEVICE_CHANNELS_REQUEST | DEVICE_FREQUENCY_REQUEST;
else
{
@@ -1937,7 +1937,8 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
{
enum DevFmtChannels chans = device->FmtChans;
ALCuint freq = device->Frequency;
- if(!FindHrtfFormat(&chans, &freq) || chans != device->FmtChans || freq != device->Frequency)
+ if(!FindHrtfFormat(device->DeviceName, &chans, &freq) ||
+ chans != device->FmtChans || freq != device->Frequency)
{
ERR("Requested format not HRTF compatible: %s, %uhz\n",
DevFmtChannelsString(device->FmtChans), device->Frequency);
@@ -2057,7 +2058,7 @@ static ALCenum UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
else
{
device->Hrtf_Status = ALC_HRTF_UNSUPPORTED_FORMAT_SOFT;
- device->Hrtf = GetHrtf(device->FmtChans, device->Frequency);
+ device->Hrtf = GetHrtf(device->DeviceName, device->FmtChans, device->Frequency);
}
if(device->Hrtf)
{