diff options
author | Chris Robinson <[email protected]> | 2014-05-11 01:36:18 -0700 |
---|---|---|
committer | Chris Robinson <[email protected]> | 2014-05-11 01:40:44 -0700 |
commit | 851a917b0347c3b47c9533f54c0a7ee1be3ffe45 (patch) | |
tree | f65e132998e82b4f3437a6e592a5880e3b0c5815 /Alc | |
parent | e78acce6523ac69aa04e17053cf5b72470eb90c1 (diff) |
Use a struct to store the source's direct gain/gainhf properties
Diffstat (limited to 'Alc')
-rw-r--r-- | Alc/ALu.c | 12 |
1 files changed, 6 insertions, 6 deletions
@@ -347,12 +347,12 @@ ALvoid CalcNonAttnSourceParams(ALactivesource *src, const ALCcontext *ALContext) /* Calculate gains */ DryGain = clampf(SourceVolume, MinVolume, MaxVolume); - DryGain *= ALSource->DirectGain * ListenerGain; - DryGainHF = ALSource->DirectGainHF; + DryGain *= ALSource->Direct.Gain * ListenerGain; + DryGainHF = ALSource->Direct.GainHF; for(i = 0;i < NumSends;i++) { - WetGain[i] = clampf(SourceVolume, MinVolume, MaxVolume); - WetGain[i] *= ALSource->Send[i].Gain * ListenerGain; + WetGain[i] = clampf(SourceVolume, MinVolume, MaxVolume); + WetGain[i] *= ALSource->Send[i].Gain * ListenerGain; WetGainHF[i] = ALSource->Send[i].GainHF; } @@ -873,8 +873,8 @@ ALvoid CalcSourceParams(ALactivesource *src, const ALCcontext *ALContext) WetGain[i] = clampf(WetGain[i], MinVolume, MaxVolume); /* Apply gain and frequency filters */ - DryGain *= ALSource->DirectGain * ListenerGain; - DryGainHF *= ALSource->DirectGainHF; + DryGain *= ALSource->Direct.Gain * ListenerGain; + DryGainHF *= ALSource->Direct.GainHF; for(i = 0;i < NumSends;i++) { WetGain[i] *= ALSource->Send[i].Gain * ListenerGain; |