diff options
author | Chris Robinson <[email protected]> | 2015-09-20 04:10:21 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2015-09-20 08:28:34 -0700 |
commit | 5f5eebc4df536daef7f68d02f7a0c751c8dc0f79 (patch) | |
tree | d86069c47e3b05437b97601102a2104a96ac7b6e /Alc/ALc.c | |
parent | 46bbf95bae605ac8be1ca163e337b33928627960 (diff) |
Allow the hrtf_tables option to be device-specific
Diffstat (limited to 'Alc/ALc.c')
-rw-r--r-- | Alc/ALc.c | 7 |
1 files changed, 4 insertions, 3 deletions
@@ -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) { |