Symptoms
- The docs state that in Unity 5.0+ you can no longer set the speakerMode via API, but instead must use project settings->audio to set this
Cause
Setting AudioSettings.speakerMode is deprecated and has been replaced by audio project settings and the AudioSettings.GetConfiguration/AudioSettings.Reset API
Resolution
If you want to change the AudioSettings, the new API must be used:
AudioConfiguration _audioConfig = AudioSettings.GetConfiguration ();
_audioConfig.speakerMode = AudioSettings.driverCapabilities;
AudioSettings.Reset (_audioConfig);
More Information
AudioSettings.GetConfiguration
AudioSettings.Reset
This article applies to Unity versions 5.0+
Comments
0 comments
Article is closed for comments.