MultipleAudioPlayer
new MultipleAudioPlayer()
- Source:
Members
audioPool :Array.<HTMLAudioElement>
- Source:
Type:
audios :Array.<HTMLAudioElement>
- Source:
Type:
panTransition :Timer|null
- Source:
Type:
panner :StereoPannerNode
- Source:
Type:
reverb :ConvolverNode|null
- Source:
Type:
volumeTransition :Timer|null
- Source:
Type:
Methods
getRecentlyAudio(guid) → {audio|undefined}
- Source:
Parameters:
| Name |
Type |
Description |
guid |
string
|
音频文件ID
|
Returns:
-
Type:
-
audio
|
undefined
play(guid, volumeopt, playbackRateopt)
- Source:
Parameters:
| Name |
Type |
Attributes |
Default |
Description |
guid |
string
|
|
|
音频文件ID
|
volume |
number
|
<optional>
|
1
|
播放音量[0-1]
|
playbackRate |
number
|
<optional>
|
1
|
播放速度
|
playAt(guid, location, volumeopt, playbackRateopt)
- Source:
Parameters:
| Name |
Type |
Attributes |
Default |
Description |
guid |
string
|
|
|
音频文件ID
|
location |
Object
|
|
|
具有场景坐标的对象
|
volume |
number
|
<optional>
|
1
|
播放音量[0-1]
|
playbackRate |
number
|
<optional>
|
1
|
播放速度
|
setLoop(loop)
- Source:
Parameters:
| Name |
Type |
Description |
loop |
boolean
|
循环播放
|
setPan(pan, easingIdopt, durationopt)
- Source:
Parameters:
| Name |
Type |
Attributes |
Description |
pan |
number
|
|
声像[-1~+1]
|
easingId |
string
|
<optional>
|
过渡曲线ID
|
duration |
number
|
<optional>
|
持续时间(毫秒)
|
setReverb(dry, wet, easingIdopt, durationopt)
- Source:
Parameters:
| Name |
Type |
Attributes |
Description |
dry |
number
|
|
干声增益[0-1]
|
wet |
number
|
|
湿声增益[0-1]
|
easingId |
string
|
<optional>
|
过渡曲线ID
|
duration |
number
|
<optional>
|
持续时间(毫秒)
|
setVolume(volume, easingIdopt, durationopt)
- Source:
Parameters:
| Name |
Type |
Attributes |
Description |
volume |
number
|
|
播放音量[0-1]
|
easingId |
string
|
<optional>
|
过渡曲线ID
|
duration |
number
|
<optional>
|
持续时间(毫秒)
|