From 16ff379ebeca2092e9609eb3163a6bd2ffd68060 Mon Sep 17 00:00:00 2001 From: Sergeanur Date: Tue, 17 Aug 2021 13:58:48 +0300 Subject: Add AUDIO_REFLECTIONS define, fix a bunch of types, fix heli chatter intensity --- src/audio/sampman_oal.cpp | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-) (limited to 'src/audio/sampman_oal.cpp') diff --git a/src/audio/sampman_oal.cpp b/src/audio/sampman_oal.cpp index 17776347..b8a3ed3d 100644 --- a/src/audio/sampman_oal.cpp +++ b/src/audio/sampman_oal.cpp @@ -1362,10 +1362,16 @@ bool8 cSampleManager::UpdateReverb(void) if ( AudioManager.m_FrameCounter & 15 ) return FALSE; - + +#ifdef AUDIO_REFLECTIONS float y = AudioManager.m_afReflectionsDistances[REFLECTION_TOP] + AudioManager.m_afReflectionsDistances[REFLECTION_BOTTOM]; float x = AudioManager.m_afReflectionsDistances[REFLECTION_LEFT] + AudioManager.m_afReflectionsDistances[REFLECTION_RIGHT]; float z = AudioManager.m_afReflectionsDistances[REFLECTION_UP]; +#else + float x = 0.0f; + float y = 0.0f; + float z = 0.0f; +#endif float normy = norm(y, 5.0f, 40.0f); float normx = norm(x, 5.0f, 40.0f); @@ -1653,7 +1659,7 @@ cSampleManager::StartPreloadedStreamedFile(uint8 nStream) bool8 cSampleManager::StartStreamedFile(uint8 nFile, uint32 nPos, uint8 nStream) { - int i = 0; + uint32 i = 0; uint32 position = nPos; char filename[MAX_PATH]; @@ -1728,7 +1734,7 @@ cSampleManager::StartStreamedFile(uint8 nFile, uint32 nPos, uint8 nStream) if ( !_pMP3List ) { nFile = 0; - _bIsMp3Active = 0; + _bIsMp3Active = FALSE; CStream *stream = aStream[nStream]; #ifdef PS2_AUDIO_PATHS if(!stream->Open(PS2StreamedNameTable[nFile], IsThisTrackAt16KHz(nFile) ? 16000 : 32000)) @@ -1767,7 +1773,7 @@ cSampleManager::StartStreamedFile(uint8 nFile, uint32 nPos, uint8 nStream) } } - _bIsMp3Active = 0; + _bIsMp3Active = FALSE; } while ( ++i < nNumMP3s ); position = 0; -- cgit v1.2.3