Struct AudioServerSingleton
Server interface for low-level audio access.
struct AudioServerSingleton
;
AudioServer
is a low-level server interface for audio access. It is in charge of creating sample data (playable audio) as well as its playback via a voice interface.
Properties
Name | Type | Description |
---|---|---|
busCount [get, set]
|
long | Number of available audio buses. |
device [get, set]
|
String | Name of the current device for audio output (see getDeviceList ).
|
globalRateScale [get, set]
|
double | Scales the rate at which audio is played (i.e. setting it to 0.5 will make the audio be played twice as fast).
|
Methods
Name | Description |
---|---|
addBus
|
Adds a bus at at_position .
|
addBusEffect
|
Adds an AudioEffect effect to the bus bus_idx at at_position .
|
captureGetDevice
|
Name of the current device for audio input (see captureGetDeviceList ).
|
captureGetDeviceList
|
Returns the names of all audio input devices detected on the system. |
captureSetDevice
|
Sets which audio input device is used for audio capture. |
generateBusLayout
|
Generates an AudioBusLayout using the available buses and effects.
|
getBusChannels
|
Returns the amount of channels of the bus at index bus_idx .
|
getBusCount
|
|
getBusEffect
|
Returns the AudioEffect at position effect_idx in bus bus_idx .
|
getBusEffectCount
|
Returns the number of effects on the bus at bus_idx .
|
getBusEffectInstance
|
Returns the AudioEffectInstance assigned to the given bus and effect indices (and optionally channel).
|
getBusIndex
|
Returns the index of the bus with the name bus_name .
|
getBusName
|
Returns the name of the bus with the index bus_idx .
|
getBusPeakVolumeLeftDb
|
Returns the peak volume of the left speaker at bus index bus_idx and channel index channel .
|
getBusPeakVolumeRightDb
|
Returns the peak volume of the right speaker at bus index bus_idx and channel index channel .
|
getBusSend
|
Returns the name of the bus that the bus at index bus_idx sends to.
|
getBusVolumeDb
|
Returns the volume of the bus at index bus_idx in dB.
|
getDevice
|
|
getDeviceList
|
Returns the names of all audio devices detected on the system. |
getGlobalRateScale
|
|
getMixRate
|
Returns the sample rate at the output of the AudioServer .
|
getOutputLatency
|
Returns the audio driver's output latency. |
getSpeakerMode
|
Returns the speaker configuration. |
getTimeSinceLastMix
|
Returns the relative time since the last mix occurred. |
getTimeToNextMix
|
Returns the relative time until the next mix occurs. |
isBusBypassingEffects
|
If true , the bus at index bus_idx is bypassing effects.
|
isBusEffectEnabled
|
If true , the effect at index effect_idx on the bus at index bus_idx is enabled.
|
isBusMute
|
If true , the bus at index bus_idx is muted.
|
isBusSolo
|
If true , the bus at index bus_idx is in solo mode.
|
lock
|
Locks the audio driver's main loop. Note: Remember to unlock it afterwards. |
moveBus
|
Moves the bus from index index to index to_index .
|
removeBus
|
Removes the bus at index index .
|
removeBusEffect
|
Removes the effect at index effect_idx from the bus at index bus_idx .
|
setBusBypassEffects
|
If true , the bus at index bus_idx is bypassing effects.
|
setBusCount
|
|
setBusEffectEnabled
|
If true , the effect at index effect_idx on the bus at index bus_idx is enabled.
|
setBusLayout
|
Overwrites the currently used AudioBusLayout .
|
setBusMute
|
If true , the bus at index bus_idx is muted.
|
setBusName
|
Sets the name of the bus at index bus_idx to name .
|
setBusSend
|
Connects the output of the bus at bus_idx to the bus named send .
|
setBusSolo
|
If true , the bus at index bus_idx is in solo mode.
|
setBusVolumeDb
|
Sets the volume of the bus at index bus_idx to volume_db .
|
setDevice
|
|
setGlobalRateScale
|
|
swapBusEffects
|
Swaps the position of two effects in bus bus_idx .
|
unlock
|
Unlocks the audio driver's main loop. (After locking it, you should always unlock it.) |
Enums
Name | Description |
---|---|
Constants
|
|
SpeakerMode
|