aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/ALu.c
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2012-02-10 00:29:47 -0800
committerChris Robinson <[email protected]>2012-02-10 00:29:47 -0800
commit61be01efc197fd2719ad2b3df0cb408d50c7b1ef (patch)
tree9070ab8d84b1e38286b7ff76b4ccf3f350815870 /Alc/ALu.c
parent23bda38be06f87aa58f504012a36bf537d52d342 (diff)
Rename SpeakerGain to ChannelGain
Diffstat (limited to 'Alc/ALu.c')
-rw-r--r--Alc/ALu.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/Alc/ALu.c b/Alc/ALu.c
index 195c6b71..ba43cb36 100644
--- a/Alc/ALu.c
+++ b/Alc/ALu.c
@@ -116,7 +116,7 @@ ALvoid CalcNonAttnSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
ALfloat WetGain[MAX_SENDS];
ALfloat WetGainHF[MAX_SENDS];
ALint NumSends, Frequency;
- const ALfloat *SpeakerGain;
+ const ALfloat *ChannelGain;
const struct ChanMap *chans = NULL;
enum Resampler Resampler;
ALint num_channels = 0;
@@ -209,13 +209,13 @@ ALvoid CalcNonAttnSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
{
pos = aluCart2LUTpos(aluCos(RearMap[c].angle),
aluSin(RearMap[c].angle));
- SpeakerGain = Device->PanningLUT[pos];
+ ChannelGain = Device->PanningLUT[pos];
for(i = 0;i < (ALint)Device->NumChan;i++)
{
enum Channel chan = Device->Speaker2Chan[i];
SrcMatrix[c][chan] += DryGain * ListenerGain *
- SpeakerGain[chan];
+ ChannelGain[chan];
}
}
}
@@ -292,13 +292,13 @@ ALvoid CalcNonAttnSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
continue;
}
pos = aluCart2LUTpos(aluCos(chans[c].angle), aluSin(chans[c].angle));
- SpeakerGain = Device->PanningLUT[pos];
+ ChannelGain = Device->PanningLUT[pos];
for(i = 0;i < (ALint)Device->NumChan;i++)
{
enum Channel chan = Device->Speaker2Chan[i];
SrcMatrix[c][chan] += DryGain * ListenerGain *
- SpeakerGain[chan];
+ ChannelGain[chan];
}
}
}
@@ -740,7 +740,7 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
{
// Use energy-preserving panning algorithm for multi-speaker playback
ALfloat DirGain, AmbientGain;
- const ALfloat *SpeakerGain;
+ const ALfloat *ChannelGain;
ALfloat length;
ALint pos;
@@ -754,7 +754,7 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
}
pos = aluCart2LUTpos(-Position[2]*ZScale, Position[0]);
- SpeakerGain = Device->PanningLUT[pos];
+ ChannelGain = Device->PanningLUT[pos];
DirGain = aluSqrt(Position[0]*Position[0] + Position[2]*Position[2]);
// elevation adjustment for directional gain. this sucks, but
@@ -769,7 +769,7 @@ ALvoid CalcSourceParams(ALsource *ALSource, const ALCcontext *ALContext)
for(i = 0;i < (ALint)Device->NumChan;i++)
{
enum Channel chan = Device->Speaker2Chan[i];
- ALfloat gain = lerp(AmbientGain, SpeakerGain[chan], DirGain);
+ ALfloat gain = lerp(AmbientGain, ChannelGain[chan], DirGain);
ALSource->Params.DryGains[0][chan] = DryGain * gain;
}
}