diff options
author | Sergeanur <s.anureev@yandex.ua> | 2021-08-29 16:32:36 +0200 |
---|---|---|
committer | Sergeanur <s.anureev@yandex.ua> | 2021-08-29 16:32:36 +0200 |
commit | a404689e505f67bd14a3102726f459f414d0379f (patch) | |
tree | f297ab6dbcd3fa8b7bc76423a82845a2e70cc3c9 /src/audio/AudioManager.cpp | |
parent | Fix tabs after merge (diff) | |
download | re3-a404689e505f67bd14a3102726f459f414d0379f.tar re3-a404689e505f67bd14a3102726f459f414d0379f.tar.gz re3-a404689e505f67bd14a3102726f459f414d0379f.tar.bz2 re3-a404689e505f67bd14a3102726f459f414d0379f.tar.lz re3-a404689e505f67bd14a3102726f459f414d0379f.tar.xz re3-a404689e505f67bd14a3102726f459f414d0379f.tar.zst re3-a404689e505f67bd14a3102726f459f414d0379f.zip |
Diffstat (limited to '')
-rw-r--r-- | src/audio/AudioManager.cpp | 22 |
1 files changed, 22 insertions, 0 deletions
diff --git a/src/audio/AudioManager.cpp b/src/audio/AudioManager.cpp index c339ea43..c4320b5d 100644 --- a/src/audio/AudioManager.cpp +++ b/src/audio/AudioManager.cpp @@ -1402,6 +1402,28 @@ cAudioManager::GenerateIntegerRandomNumberTable() m_anRandomTable[i] = myrand(); } +void +cAudioManager::DirectlyEnqueueSample(uint32 sample, uint8 bank, uint32 counter, uint32 priority, uint32 freq, uint8 volume, uint8 framesToPlay, uint32 notStereo) +{ + m_sQueueSample.m_nSampleIndex = sample; + m_sQueueSample.m_bReflections = FALSE; + m_sQueueSample.m_nLoopCount = 0; + m_sQueueSample.m_bIs2D = FALSE; + m_sQueueSample.m_bStatic = FALSE; + m_sQueueSample.m_nPan = 0; + m_sQueueSample.m_nBankIndex = bank; + m_sQueueSample.m_nCounter = counter; + m_sQueueSample.m_nFrequency = freq; + m_sQueueSample.m_nVolume = volume; + m_sQueueSample.m_nPriority = priority; + m_sQueueSample.m_nFramesToPlay = framesToPlay; + AudioManager.AddSampleToRequestedQueue(); + if (!notStereo) { + m_sQueueSample.m_nPan = 127; + AudioManager.AddSampleToRequestedQueue(); + } +} + #ifdef EXTERNAL_3D_SOUND void cAudioManager::AdjustSamplesVolume() |