summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2011-05-06 00:38:10 -0700
committerChris Robinson <[email protected]>2011-05-06 00:38:10 -0700
commit1363e044acb52e9e51e2b3dcdc6dbad823ccb06c (patch)
tree07d01ec3fa48890b48cb0da4a47095084bd5c164
parent9967d4eadded7cfc0c8424d6ffd756b85ba6f4ef (diff)
Remove the head_dampen option
Now that HRTF is properly supported, it's not needed
-rw-r--r--Alc/ALc.c12
-rw-r--r--Alc/ALu.c14
-rw-r--r--OpenAL32/Include/alMain.h3
-rw-r--r--alsoftrc.sample8
4 files changed, 0 insertions, 37 deletions
diff --git a/Alc/ALc.c b/Alc/ALc.c
index 401441b6..84478ada 100644
--- a/Alc/ALc.c
+++ b/Alc/ALc.c
@@ -1217,14 +1217,6 @@ static ALCboolean UpdateDeviceParams(ALCdevice *device, const ALCint *attrList)
device->Bs2b = NULL;
}
- device->HeadDampen = 0.0f;
- if(!(device->Flags&DEVICE_USE_HRTF) && ChannelsFromDevFmt(device->FmtChans) <= 2)
- {
- device->HeadDampen = GetConfigValueFloat(NULL, "head_dampen", DEFAULT_HEAD_DAMPEN);
- device->HeadDampen = __min(device->HeadDampen, 1.0f);
- device->HeadDampen = __max(device->HeadDampen, 0.0f);
- }
-
return ALC_TRUE;
}
@@ -2354,8 +2346,6 @@ ALC_API ALCdevice* ALC_APIENTRY alcOpenDevice(const ALCchar *deviceName)
if(GetConfigValueBool(NULL, "stereodup", AL_TRUE))
device->Flags |= DEVICE_DUPLICATE_STEREO;
- device->HeadDampen = 0.0f;
-
// Find a playback device to open
SuspendContext(NULL);
for(i = 0;BackendList[i].Init;i++)
@@ -2531,8 +2521,6 @@ ALC_API ALCdevice* ALC_APIENTRY alcLoopbackOpenDeviceSOFT(void)
if(GetConfigValueBool(NULL, "stereodup", AL_TRUE))
device->Flags |= DEVICE_DUPLICATE_STEREO;
- device->HeadDampen = 0.0f;
-
// Open the "backend"
SuspendContext(NULL);
device->Funcs = &BackendLoopback.Funcs;
diff --git a/Alc/ALu.c b/Alc/ALu.c
index 5657da22..456f9de8 100644
--- a/Alc/ALu.c
+++ b/Alc/ALu.c
@@ -666,20 +666,6 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
ConeHF = 1.0f;
}
- // Apply some high-frequency attenuation for sources behind the listener
- // NOTE: This should be aluDotproduct({0,0,-1}, ListenerToSource), however
- // that is equivalent to aluDotproduct({0,0,1}, SourceToListener), which is
- // the same as SourceToListener[2]
- Angle = aluAcos(SourceToListener[2]) * 180.0f/M_PI;
- // Sources within the minimum distance attenuate less
- if(OrigDist < MinDist)
- Angle *= OrigDist/MinDist;
- if(Angle > 90.0f)
- {
- ALfloat scale = (Angle-90.0f) / (180.1f-90.0f); // .1 to account for fp errors
- ConeHF *= 1.0f - (Device->HeadDampen*scale);
- }
-
DryGain *= ConeVolume;
if(ALSource->DryGainHFAuto)
DryGainHF *= ConeHF;
diff --git a/OpenAL32/Include/alMain.h b/OpenAL32/Include/alMain.h
index 1eb8cfe0..bb8784b7 100644
--- a/OpenAL32/Include/alMain.h
+++ b/OpenAL32/Include/alMain.h
@@ -480,9 +480,6 @@ struct ALCdevice_struct
struct bs2b *Bs2b;
ALCint Bs2bLevel;
- // Simulated dampening from head occlusion
- ALfloat HeadDampen;
-
// Device flags
ALuint Flags;
diff --git a/alsoftrc.sample b/alsoftrc.sample
index 02520c68..87ac2198 100644
--- a/alsoftrc.sample
+++ b/alsoftrc.sample
@@ -55,14 +55,6 @@
# stereo modes.
#cf_level = 0
-## head_dampen:
-# Sets the amount of dampening on sounds emanating from behind the listener.
-# This is used to simulate the natural occlusion of the head, which is
-# typically missing with mono and stereo output, and as such, only works on
-# mono and stereo output modes. Valid values range from 0 to 1 (inclusive),
-# and higher values provide a stronger effect.
-#head_dampen = 0.25
-
## frequency:
# Sets the output frequency.
#frequency = 44100