diff options
author | Nikolay Korolev <nickvnuk@gmail.com> | 2021-07-02 10:28:46 +0200 |
---|---|---|
committer | Nikolay Korolev <nickvnuk@gmail.com> | 2021-07-02 10:28:46 +0200 |
commit | 10cc444482b52d6e82b624bbbb7d87c48dcf48e2 (patch) | |
tree | 2c80031552d77909220ed7bd66a7e055aa3e5b45 /src/audio/AudioManager.cpp | |
parent | Merge remote-tracking branch 'upstream/lcs' into lcs (diff) | |
parent | Merge branch 'miami' into lcs (diff) | |
download | re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar.gz re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar.bz2 re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar.lz re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar.xz re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.tar.zst re3-10cc444482b52d6e82b624bbbb7d87c48dcf48e2.zip |
Diffstat (limited to 'src/audio/AudioManager.cpp')
-rw-r--r-- | src/audio/AudioManager.cpp | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/audio/AudioManager.cpp b/src/audio/AudioManager.cpp index b9d46d2c..c4f49e19 100644 --- a/src/audio/AudioManager.cpp +++ b/src/audio/AudioManager.cpp @@ -333,7 +333,7 @@ cAudioManager::Get3DProviderName(uint8 id) const if (!m_bIsInitialised) return nil; #ifdef AUDIO_OAL - id = clamp(id, 0, SampleManager.GetNum3DProvidersAvailable() - 1); + id = Clamp(id, 0, SampleManager.GetNum3DProvidersAvailable() - 1); #else // We don't want that either since it will crash the game, but skipping for now if (id >= SampleManager.GetNum3DProvidersAvailable()) @@ -533,7 +533,7 @@ cAudioManager::ComputeDopplerEffectedFrequency(uint32 oldFreq, float position1, if (dist != 0.0f) { float speedOfSource = (dist / m_nTimeSpent) * speedMultiplier; if (m_fSpeedOfSound > Abs(speedOfSource)) { - speedOfSource = clamp2(speedOfSource, 0.0f, 1.5f); + speedOfSource = Clamp2(speedOfSource, 0.0f, 1.5f); newFreq = (oldFreq * m_fSpeedOfSound) / (speedOfSource + m_fSpeedOfSound); } } @@ -897,11 +897,11 @@ cAudioManager::ProcessActiveQueues() sample.m_fSpeedMultiplier); if (sample.m_nFrequency != m_asActiveSamples[j].m_nFrequency) { - m_asActiveSamples[j].m_nFrequency = clamp2((int32)sample.m_nFrequency, (int32)m_asActiveSamples[j].m_nFrequency, 6000); + m_asActiveSamples[j].m_nFrequency = Clamp2((int32)sample.m_nFrequency, (int32)m_asActiveSamples[j].m_nFrequency, 6000); SampleManager.SetChannelFrequency(j, m_asActiveSamples[j].m_nFrequency); } if (sample.m_nEmittingVolume != m_asActiveSamples[j].m_nEmittingVolume) { - vol = clamp2((int8)sample.m_nEmittingVolume, (int8)m_asActiveSamples[j].m_nEmittingVolume, 10); + vol = Clamp2((int8)sample.m_nEmittingVolume, (int8)m_asActiveSamples[j].m_nEmittingVolume, 10); if (field_4) { emittingVol = 2 * Min(63, vol); |