Legacy Documentation: Version 4.5.0

Script language:

  • JS
  • C#
  • Boo
Script language

Select your preferred scripting language. All code snippets will be displayed in this language.

AudioSettings.driverCaps

static var driverCaps: AudioSpeakerMode;
static AudioSpeakerMode driverCaps;
static driverCaps as AudioSpeakerMode

Description

Returns the speaker mode capability of the current audio driver. (Read Only)

	// Set the speaker mode to that of the system settings.

AudioSettings.speakerMode = AudioSettings.driverCaps;

using UnityEngine;
using System.Collections;

public class ExampleClass : MonoBehaviour {
    void Example() {
        AudioSettings.speakerMode = AudioSettings.driverCaps;
    }
}
import UnityEngine
import System.Collections

public class ExampleClass(MonoBehaviour):

	def Example() as void:
		AudioSettings.speakerMode = AudioSettings.driverCaps