找回密碼
 注冊帳號

掃一掃,訪問微社區

audiosettings.speakermode 揚聲器模式

2015-1-3 11:37| 發布者: 楊炎| 查看: 3500| 評論: 0|原作者: 蠻牛|來自: unity3d腳本manual

摘要: audiosettings.speakermode 揚聲器模式static varspeakermode:audiospeakermodedescription描述sets or gets the current speaker mode. default is 2 channel stereo.設置或獲取當前揚聲器的模式。默認為2聲道立體 ...

audiosettings.speakermode 揚聲器模式

static varspeakermode:audiospeakermode

description描述

sets or gets the current speaker mode. default is 2 channel stereo.

設置或獲取當前揚聲器的模式。默認為2聲道立體聲。

be aware that the audio system is bootstrapped, when a new speaker mode is set, meaning that all playing audiosources are stopped. if a speaker mode is set beyond the drivers capability, the audio behaviour is undefined. useaudiosettings.drivercapsto get the capabilities of the current driver.

請注意,音頻系統是引導程序,當一個新的揚聲器模式設置,這意味著所有正播放的音頻源被停止。如果揚聲器模式設置超出了驅動程序功能,則音頻的行為是未定義的。使用audiosettings.drivercaps獲取當前驅動程序的功能。

c#

javascript

using unityengine;

using system.collections;

public class example :monobehaviour{

public void awake() {

audiosettings.speakermode=audiosettings.drivercaps;

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

//設置揚聲器模式到系統的設置

audiosettings.speakermode=audiosettings.drivercaps;

相關閱讀

文章點評
相關文章
女校游泳队彩金