diff options
| author | robojumper <robojumper@gmail.com> | 2025-05-26 01:31:35 +0200 |
|---|---|---|
| committer | robojumper <robojumper@gmail.com> | 2025-05-26 01:31:35 +0200 |
| commit | 913b135a0fa7282848f94dd590e736c47d662fce (patch) | |
| tree | 1a19f2ead9df32ea83840b9a2fbc777da98dc15f /src/nw4r | |
| parent | 05c763814bdfe3a79d79e1f732c66b978772692b (diff) | |
snd_Channel OK
Diffstat (limited to 'src/nw4r')
| -rw-r--r-- | src/nw4r/snd/snd_Channel.cpp | 18 |
1 files changed, 9 insertions, 9 deletions
diff --git a/src/nw4r/snd/snd_Channel.cpp b/src/nw4r/snd/snd_Channel.cpp index 98b85285..3d3456d8 100644 --- a/src/nw4r/snd/snd_Channel.cpp +++ b/src/nw4r/snd/snd_Channel.cpp @@ -247,12 +247,6 @@ void Channel::Update(bool doPeriodicProc) f32 mainSend = 0.0f; mainSend += mMainSend; - - f32 remoteOutVolume[4]; - for (int i = 0; i < 4; i++) { - remoteOutVolume[i] = 1.0f; - remoteOutVolume[i] *= mRemoteOutVolume[i]; - } f32 fxSend[AUX_BUS_NUM]; for (int i = 0; i < AUX_BUS_NUM; i++) @@ -261,6 +255,12 @@ void Channel::Update(bool doPeriodicProc) fxSend[i] += mFxSend[i]; } + f32 remoteOutVolume[4]; + for (int i = 0; i < 4; i++) { + remoteOutVolume[i] = 1.0f; + remoteOutVolume[i] *= mRemoteOutVolume[i]; + } + if (doPeriodicProc) { if (mAutoSweep) @@ -294,12 +294,12 @@ void Channel::Update(bool doPeriodicProc) mVoice->SetMainOutVolume(mainOutVolume); mVoice->SetMainSend(mainSend); + for (int i = 0; i < AUX_BUS_NUM; i++) + mVoice->SetFxSend(static_cast<AuxBus>(i), fxSend[i]); + for (int i = 0; i < 4; i++) { mVoice->SetRemoteOutVolume(i, remoteOutVolume[i]); } - - for (int i = 0; i < AUX_BUS_NUM; i++) - mVoice->SetFxSend(static_cast<AuxBus>(i), fxSend[i]); } } |
