aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2007-03-17 15:54:37 +0000
committerthilo <thilo@edf5b092-35ff-0310-97b2-ce42778d08ea>2007-03-17 15:54:37 +0000
commit5aa77e3afbe6f455183a90289f4bf91fcccfefd9 (patch)
tree54e6a291cbfb25ac6ace8b81ef0495177fc10075
parentd13b3695113e9843c50b8c9712dabd9df2a4d442 (diff)
downloadioquake3-aero-5aa77e3afbe6f455183a90289f4bf91fcccfefd9.tar.gz
ioquake3-aero-5aa77e3afbe6f455183a90289f4bf91fcccfefd9.zip
Remove cvar s_alMaxSpeakerDistance for the same task can better be achieved with s_alMaxDistance.
git-svn-id: svn://svn.icculus.org/quake3/trunk@1051 edf5b092-35ff-0310-97b2-ce42778d08ea
-rw-r--r--README2
-rw-r--r--code/client/snd_openal.c6
2 files changed, 2 insertions, 6 deletions
diff --git a/README b/README
index d5d0c17..da52d20 100644
--- a/README
+++ b/README
@@ -125,8 +125,6 @@ New cvars
source
s_alGraceDistance - after having passed MaxDistance, length
until sounds are completely inaudible.
- s_alMaxSpeakerDistance - ET_SPEAKERS beyond this distance are
- culled
s_alDriver - which OpenAL library to use
s_alDevice - which OpenAL device to use
s_alAvailableDevices - list of available OpenAL devices
diff --git a/code/client/snd_openal.c b/code/client/snd_openal.c
index b20e411..a93c2d2 100644
--- a/code/client/snd_openal.c
+++ b/code/client/snd_openal.c
@@ -42,7 +42,6 @@ cvar_t *s_alGraceDistance;
cvar_t *s_alDriver;
cvar_t *s_alDevice;
cvar_t *s_alAvailableDevices;
-cvar_t *s_alMaxSpeakerDistance;
/*
=================
@@ -1096,8 +1095,8 @@ void S_AL_AddRealLoopingSound( int entityNum, const vec3_t origin, const vec3_t
// There are certain maps (*cough* Q3:TA mpterra*) that have large quantities
// of ET_SPEAKERS in the PVS at any given time. OpenAL can't cope with mixing
// large numbers of sounds, so this culls them by distance
- if( DistanceSquared( origin, lastListenerOrigin ) >
- s_alMaxSpeakerDistance->value * s_alMaxSpeakerDistance->value )
+ if( DistanceSquared( origin, lastListenerOrigin ) > (s_alMaxDistance->value + s_alGraceDistance->value) *
+ (s_alMaxDistance->value + s_alGraceDistance->value) )
return;
S_AL_SrcLoop(SRCPRI_AMBIENT, sfx, origin, velocity, entityNum);
@@ -1883,7 +1882,6 @@ qboolean S_AL_Init( soundInterface_t *si )
s_alMaxDistance = Cvar_Get("s_alMaxDistance", "1024", CVAR_CHEAT);
s_alRolloff = Cvar_Get( "s_alRolloff", "2", CVAR_CHEAT);
s_alGraceDistance = Cvar_Get("s_alGraceDistance", "512", CVAR_CHEAT);
- s_alMaxSpeakerDistance = Cvar_Get( "s_alMaxSpeakerDistance", "1024", CVAR_ARCHIVE );
s_alDriver = Cvar_Get( "s_alDriver", ALDRIVER_DEFAULT, CVAR_ARCHIVE );