Search Unity

Bug Audio.Audio Mixer Thread - VUFader makes 864 calls with only 16 playing audio source in editor

Discussion in 'Audio & Video' started by theotherstudio13, Jul 25, 2021.

  1. theotherstudio13

    theotherstudio13

    Joined:
    Oct 8, 2009
    Posts:
    46
    VUFader is very spikey it jumps from 18 to 800+ calls. This problem is much deeper than I as an audio designer can debug. If anyone on the unity audio team can help just DM me our reach out and I can provide as much detail as you need.

    Unity version 2019.3.9f1 . The project is moderately complex the project is "AA" we're using unity native audio.

    We have an audio framework that creates an audio source for every 'voice' needed in a scene. We expected
    Unity's built in audio system to be efficiently handling hundreds of audio source in a scene using a combination of pre-existing features like :
    • Projects Settings - max voices
    • Audio Source - priority
    • Unity Audio Engine - virtualization
    • Audio Mixer - auto suspend mixer

    When a typical scene runs we have hundreds of audio source as expected but only 16 playing at any one time due to setting max voices to 16. It appears that max voices , priority and virtualization are all working correctly. However we're getting really high audio dsp number like 42%.
    We're not using any effects directly on audio source, 1 single reverb on the audio mixer, and about 6 ducking effects.

    In the profiler we can see CPU / Audio.Audio Mixer Thread / VUFader is spiking to 864 calls with only 16 audio source playing. This looks like the source of our problem because all the other mixer thread numbers are very low for example SFX Reverb is 1.5%. There are a few clips as stereo but most are mono. The mixer is running in stereo as my windows output is stereo. My audio mixer architecture is moderately complex with mixers nested serval layers deep the deepest being 5 hops.

    STAMP Unity VUFader.JPG

    STAMP Unity audio tab2.JPG

    STAMP Unity game stats2.JPG