AudioMixer.SetFloat and Snapshots working in Editor but not on iOS/Android

I have an issue discovered when using Event sounds by Master Audio for audio mixer snapshot transitions working in editor but not on mobile.

What I want to do is to change filter frequencies and send levels in nested audio groups inside the AudioMixer. It works perfectly in the Editor, but not on any mobile device.

When snapshots apparently didn’t work, I made a script that replicated the transition. Worked perfectly in the editor, but not on mobile devices. More details below.

Steps Taken to Troubleshoot:

  1. Effects: Ensuring the filters and effects work at all by manually turning them on before building. All of them work in both the editor and on mobile devices. This tells me the effects and the AudioMixer are pesent on mobile, since I can hear them.
  2. Exposed Parameter Testing: Confirmed that parameters are correctly exposed and accessible via SetFloat. Testing has included adjustments to both nested groups and the Master group within the AudioMixer.
  3. Snapshot Transitions: Configured and tested snapshots with differing parameter settings, transitioning between them using audioMixer.TransitionToSnapshots —audible in the Editor but not on mobile.
  4. Simplified Configuration: Applied volume and pitch adjustments directly to the Master group to isolate the issue from nested group structures —audible in the Editor but not on mobile.
  5. Platform specific paths: Tried using full paths to the affected nested mixer groups, however this made them unrecognizable in the script on mobile.
  6. Interpolation and Batching: Replaced Mathf.Lerp with Mathf.SmoothStep for smoother interpolation and batched parameter changes, applying them simultaneously to improve consistency on mobile —no effect on mobile.
  7. Event Timing: Moved initialization from OnEnable to Start per Unity’s documentation on mobile —no difference in the Editor and no effect on mobile.
  8. Direct Parameter Application with SetParameter: Implemented a wrapper method, SetParameter, to apply values directly. —working in the Editor and no effect on mobile.
  9. Audio Mixer Settings: DSP Buffer Size set to Best Latency (256), DSP Buffer Size set to Best Performance (1024), ; Sample Rate 44100 Hz —no difference in the Editor and no effect on mobile.

Environment:

  • Unity Version: 2022.3.51f1
  • Platforms Affected: iOS and Android

Observed Behavior:

  • Both SetFloat and TransitionToSnapshots calls execute and apply as expected in the Unity Editor with audible effects.
  • Debug logs confirm that all parameter values update as intended on mobile, yet no audible changes are detected.
  • Same settings and code produce the expected audio effects in the Editor but remain silent on mobile, even when simplified to the Master group alone.

Key Questions:

  1. Examples: Are there any examples of successful cases with AudioMixer real time manipulation on mobile devices?
  2. Platform-Specific Limitations: Are there any documented issues or platform-specific limitations with AudioMixer.SetFloat, snapshots, or AudioMixer in general on iOS and Android that could be causing this behavior?
  3. Recommended Approaches for Mobile: Are there alternative methods recommended for achieving real-time parameter adjustments on mobile that would bypass the current limitations of SetFloat and snapshot transitions?
  4. Additional Debugging Tools: Are there tools or diagnostic flags to verify if mobile platforms are actually processing AudioMixer parameter changes?

Did you use AssetBundle? You can use GetInstanceID() to check the differences between the mixer asset ref and the AudioSource.mixerGroup.mixer instance. They are not equal.