diff --git a/cleo_plugins/Audio/C3DAudioStream.cpp b/cleo_plugins/Audio/C3DAudioStream.cpp index e3e86d63..fe4766b1 100644 --- a/cleo_plugins/Audio/C3DAudioStream.cpp +++ b/cleo_plugins/Audio/C3DAudioStream.cpp @@ -121,15 +121,15 @@ void C3DAudioStream::UpdatePosition() } else // listener inside sound soruce, no lef-right panning or Doppler effects then { - // blending curve - outsideness = max(2.0f * outsideness - 1.0f, 0.0f); // blending curve + auto fakeVel = velocity * outsideness + CSoundSystem::velocity * (1.0f - outsideness); // blend + + // modify blending curve for stereo panning + outsideness = max(2.0f * outsideness - 1.0f, 0.0f); outsideness *= outsideness; auto fakePos = CSoundSystem::position + CSoundSystem::forward; // 1 meter in front of the listener, dead center fakePos = position * outsideness + fakePos * (1.0f - outsideness); // blend - auto fakeVel = velocity * outsideness + CSoundSystem::velocity * (1.0f - outsideness); // blend - BASS_ChannelSet3DPosition(streamInternal, &toBass(fakePos), &toBass(direction), diff --git a/cleo_plugins/Audio/CAudioStream.cpp b/cleo_plugins/Audio/CAudioStream.cpp index e30215d1..fbeb9f33 100644 --- a/cleo_plugins/Audio/CAudioStream.cpp +++ b/cleo_plugins/Audio/CAudioStream.cpp @@ -210,6 +210,8 @@ void CAudioStream::ProcessTransitions(bool instant) void CAudioStream::ApplyParams() { + if (CSoundSystem::skipFrame) return; + // volume float volume = CalculateVolume(); BASS_ChannelSetAttribute(streamInternal, BASS_ATTRIB_VOL, volume);