Audio pops and crackles with new audio mixer

Alright - I tracked down the culprit!

It’s due to an optimization I checked in for 4.16 for parameter updates. The problem is that the parameter interpolators were getting previous lifetime values and lerping from THOSE values to target values rather than properly initializing at the target value if it was the first value set. So when muting, it was lerping from non-zero values to zero values in one audio callback buffer.

The fix is super simple.

In AudioMixerSourceManager.h, in the FSourceParam class, add the following changes:

Then in AudioMixerSourceManager.cpp, switch these functions from Reset() to Init() inside FMixerSourceManager::ReleaseSource():

212813-source-param2.png

This will make sure when a source begins to play, the param interpolators will instantly set their values to the target value vs lerping to the target value.

This is a great bug find and I’m going to try and get this into the next 4.17.2 hotfix as this is going to cause issues with source param lerping in general (will cause unintended pitch-shifting, LPF lerping, etc).

Thank you so much for bringing it to my attention and I apologize for the inconvenience!