You've already forked UnrealEngineUWP
mirror of
https://github.com/izzy2lost/UnrealEngineUWP.git
synced 2026-03-26 18:15:20 -07:00
UE-18996 popping sound after flying through gates
- Adding clamps to volume output for iOS volume to avoid clipping. [CL 2633104 by Aaron McLeran in Main branch]
This commit is contained in:
committed by
Aaron.McLeran@epicgames.com
parent
33faf00462
commit
41be88d27a
@@ -257,10 +257,12 @@ void FIOSAudioSoundSource::Update(void)
|
||||
}
|
||||
|
||||
// Apply global multiplier to disable sound when not the foreground app
|
||||
Volume = FMath::Clamp(Volume, 0.0f, MAX_VOLUME) * FApp::GetVolumeMultiplier() * AudioDevice->PlatformAudioHeadroom;
|
||||
Volume *= FApp::GetVolumeMultiplier();
|
||||
Volume *= AudioDevice->PlatformAudioHeadroom;
|
||||
Volume = FMath::Clamp(Volume, 0.0f, 1.0f);
|
||||
|
||||
// Convert to dB
|
||||
const AudioUnitParameterValue Gain = FMath::Clamp<float>(20.0f * log10(Volume), -100, 20.0f);
|
||||
const AudioUnitParameterValue Gain = FMath::Clamp<float>(20.0f * log10(Volume), -100, 0.0f);
|
||||
const AudioUnitParameterValue Pitch = FMath::Clamp<float>(WaveInstance->Pitch, MIN_PITCH, MAX_PITCH);
|
||||
|
||||
OSStatus Status = noErr;
|
||||
|
||||
Reference in New Issue
Block a user