AudioServer
Category: Core
Server interface for low level audio access.
Methods
- bus_layout_changed ( )
Emitted when the changes.
Enumerations
enum SpeakerMode:
- SPEAKER_MODE_STEREO = 0 — Two or fewer speakers are detected.
- SPEAKER_SURROUND_31 = 1
- SPEAKER_SURROUND_51 = 2 — A 5.1 channel surround setup detected.
- SPEAKER_SURROUND_71 = 3 — A 7.1 channel surround setup detected.
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.
Tutorials
- void add_bus ( at_position=-1 )
Adds a bus at .
Adds an effect to the bus bus_idx
at at_position
.
- String capture_get_device ( )
- capture_get_device_list ( )
- AudioBusLayout generate_bus_layout ( ) const
Generates an using the available buses and effects.
- int get_bus_channels ( bus_idx ) const
Returns the amount of channels of the bus at index bus_idx
.
- int get_bus_count ( ) const
Returns the number of available buses.
- get_bus_effect ( int bus_idx, effect_idx )
Returns the AudioEffect at position effect_idx
in bus bus_idx
.
- get_bus_effect_count ( int bus_idx )
Returns the number of effects on the bus at bus_idx
.
- get_bus_index ( String bus_name ) const
- get_bus_name ( int bus_idx ) const
Returns the name of the bus with the index bus_idx
.
- get_bus_peak_volume_left_db ( int bus_idx, channel ) const
Returns the peak volume of the left speaker at bus index bus_idx
and channel index channel
.
Returns the peak volume of the right speaker at bus index bus_idx
and channel index channel
.
- get_bus_send ( int bus_idx ) const
Returns the name of the bus that the bus at index bus_idx
sends to.
- get_bus_volume_db ( int bus_idx ) const
Returns the volume of the bus at index bus_idx
in dB.
- get_device ( )
- Array get_device_list ( )
- get_mix_rate ( ) const
Returns the sample rate at the output of the audioserver.
- SpeakerMode get_speaker_mode ( ) const
Returns the speaker configuration.
- is_bus_bypassing_effects ( int bus_idx ) const
If , the bus at index bus_idx
is bypassing effects.
If true
, the effect at index effect_idx
on the bus at index bus_idx
is enabled.
- is_bus_mute ( int bus_idx ) const
If true
, the bus at index bus_idx
is muted.
- is_bus_solo ( int bus_idx ) const
If true
, the bus at index bus_idx
is in solo mode.
- void lock ( )
Locks the audio drivers mainloop. Remember to unlock it afterwards.
- void move_bus ( index, int to_index )
- void remove_bus ( index )
Removes the bus at index index
.
- void remove_bus_effect ( int bus_idx, effect_idx )
Removes the effect at index effect_idx
from the bus at index bus_idx
.
- void set_bus_bypass_effects ( int bus_idx, enable )
If true
, the bus at index is bypassing effects.
- void set_bus_count ( int amount )
Adds and removes buses to make the number of buses match amount
.
- void set_bus_effect_enabled ( bus_idx, int effect_idx, enabled )
If true
, the effect at index effect_idx
on the bus at index bus_idx
is enabled.
- void set_bus_layout ( AudioBusLayout bus_layout )
Overwrites the currently used .
- void set_bus_mute ( int bus_idx, enable )
If true
, the bus at index bus_idx
is muted.
- void set_bus_name ( int bus_idx, name )
Sets the name of the bus at index bus_idx
to name
.
- void set_bus_send ( int bus_idx, send )
Connects the output of the bus at bus_idx
to the bus named send
.
- void set_bus_solo ( int bus_idx, enable )
If true
, the bus at index bus_idx
is in solo mode.
- void set_bus_volume_db ( int bus_idx, volume_db )
Sets the volume of the bus at index bus_idx
to volume_db
.
- void set_device ( String device )
- void swap_bus_effects ( bus_idx, int effect_idx, by_effect_idx )
Swaps the position of two effects in bus .