UE4.25 Audio Engine Bugs - Update from 4.22 - need help!

Also it looks like it might be possible that your iOS projects didn’t get updated to using the new AudioMixer, can you confirm that it is using the new AudioMixer?

Check to see if:


UseAudioMixer=true 

is set in your IOSEngine.ini?

I noticed this bug right away on 4.23 all the way up to 4.25 on the iPhone 5S. Still haven’t found any links or solutions.

Yes, exactly the same issue. In my game there is more sound effects like shooting and exploding along with the bcakground music. I just need 30 second to get the same issue.

I can find the


UseAudioMixer=true 

in my Project\Saved\Temp\IOS\Engine\Config\IOS\IOSEngine.ini

So this issue might be start at 4.23. I still remember 4.23 have bugs to remote build to iOS, lots of developers stay at 4.22 just like me, now we must update to support iOS13 so ppl start to update to 4.25. That’s why this issue could be turn out so late.

The problem is we do not have an internal reproduction of this issue. As you know Fortnite is on iOS and has been updated successfully, so it’s important that we get more information about your specific case if we hope to resolve these problems.

Having more than one game reproduce the issue is good, because we can compare data and see if there are commonalities.

Logs would be VERY useful.

So I monitored the Device Output log from a Dev Build running on iPhone 6 and the log throws this every time the audio glitches:

May 27 12:26:14 Wards-iPhone DubBoxingv1[684] <Notice>: [UE4] [2020.05.27-19.26.14:306][446]LogAudioMixer: Display: Audio Buffer Underrun detected.

There are tons of them, as stated earlier it gets worse over time. They grow one every few seconds whether anything is happening in game or not (beyond background music). They are in game regardless of buffer size settings (512/1024/2048 seem to make little to no difference). “Number of Buffers To Enque” is 1 from what I just tested but the problem is there with 2 also. Source Workers settings is kept at 0. Test was done with sample rate at 44100 but builds with sample rate at 22,050 had same problem. Any quick ideas I am over looking? I can provide full log if need be.

Thanks

Buffer underruns happen when it’s time to play audio and the audio engine hasn’t finished rendering all the audio, so it’s late and it drops the buffer and submits silence.

You can try enquing more buffers, this would be like double or tripling buffers.

Does graphic rendering compete with audio rendering? Like could texture pooling be indirectly causing Audio Underruns or anything like that? I tried ridiculously high buffer settings and unplugged ALL audio nodes with the exception of background music and within 8 minutes of play my log is growing with Audio Buffer Under Runs every few seconds. It’s totally unplayable even with no audio nodes plugged in and the ridiculously low audio settings attached. As stated, I have an earlier version of the same game packaged from 4.22 which doesn’t have a single noticeable hick up in audio. Unfortunately i’ve built too much on 4.24 to roll back.

The game also has no logic connected to event tick beyond touch sensitivity so this is quite a head scratcher. Unless anyone has any suggestions my next move is to create a blank project with nothing but background music, see if that gives me Underrun errors. If it doesn’t I will migrate my current game over and see if that miraculously solves.

Last thought before bed, could the phone temperature be the cause? I did notice a “Temperature Change: Bad” notice in the log. It wasn’t common but would explain why the audio gets corrupted with time if it’s a temperature issue. But why would frame rate remain unaffected?

Can you run it with the console command -noaudio?

^^ Check video, that is a blank project with only a single looping audio file playing on iphone 6. It still throws up Buffer Under run errors. I do NOT get buffer underrun errors if the audio is triggered to play but volume is set to zero. I DO get buffer errors if the volume is .01 or greater. Adjusting buffer settings does not appear to have any effect on the frequency of the error. It is consistent and should be easy to re-produce.

Your music is triggered from the Game Mode? Interesting.

What if you just play the music from the Level script?

What model phone are you testing your game on? I am concluding phones that don’t run iOS 13 aren’t priority enough to spend much time on with issues like this. Understandable but would be nice to know so I don’t waste my time trying to weed out a bug that exists on blank projects. I like to build apps on the lowest phone model the engine prioritizes. I am guessing that is iPhone 7 (since that runs iOS 13)???

Starting audio from level bp still gives audio underrun errors on blank project (iPhone 6).

Thanks

@Allenheathx would you mind creating a bug issue with a zipped up version of your test project? I want to pass it on to our QA compatibility testers.

Sorry for get back so late. Crazy busy last week.

@Allenheathx I always do the safe-test-strategy for iOS devices: tested on the base model but lasted version of iOS. So I tested on both iPhoneSE & iPad6 running on the lastest iOS 13.

I saw your video and agree with you

I think it’s not hardware related. It’s a software issue, even a blank project running on the iOS could re-produce this.

@dan.reynolds Did you guys find out the issue? or fixed it already? I could do the test project for it if not. It should be a quick fix, how could you guys allow such level of bug exist so long.

DeviceOutPutLog:[UE4] [2020.06.10-14.33.14:303][994]LogAudioMixer: Display: Audio Buffer Underrun detected.
This is the reason caused sound lag. But why?

I find it is not easy to re-produce this issue on a new blank project in 4.25. I tried to migrate some sound files to a new blank project but the issue didn’t show again.

But when I move all the project to the new blank project, the issue did show again. It is more complex than I thought.

Still working on this. Any idea to fix this Buffer issue?

@dan.reynolds
@Allenheathx

Oh My GOD~

After hundreds time of trying. Finally let me found out where it come from.** It’s AudioMixer.**

The log sad it is LogAudioMixer issue and I still remember Dan mentioned this setting. So I tried **UseAudioMixer=False remotebuild and run, it is gone! **

Oh,I need a break. Nearly a month fight for this.

OK,let’s finished it.

@dan.reynolds what is this new AudioMixer, what will happens after changed to UseAudioMixer=False, anything I should concern?

I hope to god your right. I bought a new phone to test on that just came in the mail today. Will try this on iphone 6 tomorrow and see if it solves.

Uhhhh guysss, I am having the EXACT SAME issue here, so glad I found this thread!
We moved from 4.22 to 4.24 and than 4.25 too.
Though setting UseAudioMixer=False results in having no sound AT ALL…
What am I doing wrong here?

The AudioMixer is the Unreal Audio Engine native audio rendering layer. It was in beta until 4.24 where it became the default audio rendering pathway for Unreal Engine. We only did this after successfully switching Fortnite to using it on all of Fortnite’s supported platforms including Android, iOS, and Switch.

Fortnite is our yardstick for Unreal Audio Engine’s mobile platform support, so iPhone 6S/6S Plus or newer.

Are you on an older iOS device?

Hi Dan we are running on an Iphone 6s and 6s+ running iOS 13.
We did not encounter these issues in 4.22
Also, this issue is not present on android devices.