From 3ac7cc9e574901027f54d97550ddf0ef848a15a3 Mon Sep 17 00:00:00 2001 From: Grosskopf Date: Tue, 10 Oct 2017 16:00:10 +0200 Subject: [PATCH] updated AudioStream docs and added AudioServer docs --- doc/classes/AudioBusLayout.xml | 2 ++ doc/classes/AudioServer.xml | 37 +++++++++++++++++++++++++++++ doc/classes/AudioStreamPlayback.xml | 2 ++ doc/classes/AudioStreamPlayer.xml | 10 ++++++-- doc/classes/AudioStreamPlayer2D.xml | 5 ++-- doc/classes/AudioStreamPlayer3D.xml | 5 ++-- 6 files changed, 55 insertions(+), 6 deletions(-) diff --git a/doc/classes/AudioBusLayout.xml b/doc/classes/AudioBusLayout.xml index e5b17b8dfb7..045c6c2bf96 100644 --- a/doc/classes/AudioBusLayout.xml +++ b/doc/classes/AudioBusLayout.xml @@ -1,8 +1,10 @@ + Stores information about the audiobusses. + Stores position, muting, solo, bypass, effects, effect position, volume, and the connections between busses. See [AudioServer] for usage. diff --git a/doc/classes/AudioServer.xml b/doc/classes/AudioServer.xml index 768987fd0b1..0a59da5355b 100644 --- a/doc/classes/AudioServer.xml +++ b/doc/classes/AudioServer.xml @@ -17,6 +17,7 @@ + Adds a bus at [code]at_position[/code]. @@ -29,18 +30,21 @@ + Adds an [AudioEffect] effect to the bus [code]bus_idx[/code] at [code]at_position[/code]. + Generates an [AudioBusLayout] using the available busses and effects. + Returns the number of available busses. @@ -51,6 +55,7 @@ + Returns the [AudioEffect] at position [code]effect_idx[/code] in bus [code]bus_idx[/code]. @@ -59,6 +64,7 @@ + Returns the number of effects on the bus at [code]bus_idx[/code]. @@ -67,6 +73,7 @@ + Returns the index of the bus with the name [code]bus_name[/code]. @@ -75,6 +82,7 @@ + Returns the name of the bus with the index [code]bus_idx[/code]. @@ -85,6 +93,7 @@ + Returns the peak volume of the left speaker at bus index [code]bus_idx[/code] and channel index [code]channel[/code]. @@ -95,6 +104,7 @@ + Returns the peak volume of the right speaker at bus index [code]bus_idx[/code] and channel index [code]channel[/code]. @@ -103,6 +113,7 @@ + Returns the name of the bus that the bus at index [code]bus_idx[/code] sends to. @@ -111,18 +122,21 @@ + Returns the volume of the bus at index [code]bus_idx[/code] in dB. + Returns the sample rate at the output of the audioserver. + Returns the speaker configuration. @@ -131,6 +145,7 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is bypassing effects. @@ -141,6 +156,7 @@ + If [code]true[/code] the effect at index [code]effect_idx[/code] on the bus at index [code]bus_idx[/code] is enabled. @@ -149,6 +165,7 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is muted. @@ -157,12 +174,14 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is in solo mode. + Locks the audio drivers mainloop. Remember to unlock it afterwards. @@ -173,6 +192,7 @@ + Moves the bus from index [code]index[/code] to index [code]to_index[/code]. @@ -181,6 +201,7 @@ + Removes the bus at index [code]index[/code]. @@ -191,6 +212,7 @@ + Removes the effect at index [code]effect_idx[/code] from the bus at index [code]bus_idx[/code]. @@ -201,6 +223,7 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is bypassing effects. @@ -209,6 +232,7 @@ + Adds and removes busses to make the number of busses match [code]amount[/code]. @@ -221,6 +245,7 @@ + If [code]true[/code] the effect at index [code]effect_idx[/code] on the bus at index [code]bus_idx[/code] is enabled. @@ -229,6 +254,7 @@ + Overwrites the currently used [AudioBusLayout]. @@ -239,6 +265,7 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is muted. @@ -249,6 +276,7 @@ + Sets the name of the bus at index [code]bus_idx[/code] to [code]name[/code]. @@ -259,6 +287,7 @@ + Connects the output of the bus at [code]bus_idx[/code] to the bus named [code]send[/send]. @@ -269,6 +298,7 @@ + If [code]true[/code] the bus at index [code]bus_idx[/code] is in solo mode. @@ -279,6 +309,7 @@ + Sets the volume of the bus at index [code]bus_idx[/code] to [code]volume_db[/code]. @@ -291,27 +322,33 @@ + Swaps the position of two effects in bus [code]bus_idx[/code]. + Unlocks the audiodriver's main loop. After locking it always unlock it. + Emitted when the [AudioBusLayout] changes. + Two or fewer speakers are detected. + A 5.1 channel surround setup detected. + A 7.1 channel surround setup detected. diff --git a/doc/classes/AudioStreamPlayback.xml b/doc/classes/AudioStreamPlayback.xml index 30a9a8f070d..f45beec42ca 100644 --- a/doc/classes/AudioStreamPlayback.xml +++ b/doc/classes/AudioStreamPlayback.xml @@ -1,8 +1,10 @@ + Meta class for playing back audio. + Can play, loop, pause a scroll through Audio. See [AudioStream] and [AudioStreamOGGVorbis] for usage. diff --git a/doc/classes/AudioStreamPlayer.xml b/doc/classes/AudioStreamPlayer.xml index 9b104fe7576..1a9ad855655 100644 --- a/doc/classes/AudioStreamPlayer.xml +++ b/doc/classes/AudioStreamPlayer.xml @@ -7,6 +7,7 @@ Plays background audio. + http://docs.godotengine.org/en/latest/learning/features/audio/index.html @@ -27,6 +28,7 @@ + Returns the position in the [AudioStream]. @@ -121,15 +123,16 @@ - If [code]true[/code], audio plays when added to scene tree. Default value: [code]false[/code]. + If [code]true[/code] audio plays when added to scene tree. Default value: [code]false[/code]. Bus on which this audio is playing. + If the audio configuration has more than two speakers, this sets the target channels. See [code]MIX_TARGET_*[/code] constants. - If [code]true[/code], audio is playing. + If [code]true[/code] audio is playing. The [AudioStream] object to be played. @@ -147,10 +150,13 @@ + The audio will be played only on the first channel. + The audio will be played on all surround channels. + The audio will be played on the second channel, which is usually the center. diff --git a/doc/classes/AudioStreamPlayer2D.xml b/doc/classes/AudioStreamPlayer2D.xml index 600e0858dd9..c6fd8ff54fe 100644 --- a/doc/classes/AudioStreamPlayer2D.xml +++ b/doc/classes/AudioStreamPlayer2D.xml @@ -40,6 +40,7 @@ + Returns the position in the [AudioStream]. @@ -156,7 +157,7 @@ Dampens audio over distance with this as an exponent. - If [code]true[/code], audio plays when added to scene tree. Default value: [code]false[/code]. + If [code]true[/code] audio plays when added to scene tree. Default value: [code]false[/code]. Bus on which this audio is playing. @@ -165,7 +166,7 @@ Maximum distance from which audio is still hearable. - If [code]true[/code], audio is playing. + If [code]true[/code] audio is playing. The [AudioStream] object to be played. diff --git a/doc/classes/AudioStreamPlayer3D.xml b/doc/classes/AudioStreamPlayer3D.xml index 886b2b975a8..2085b35e2e7 100644 --- a/doc/classes/AudioStreamPlayer3D.xml +++ b/doc/classes/AudioStreamPlayer3D.xml @@ -82,6 +82,7 @@ + Returns the position in the [AudioStream]. @@ -288,7 +289,7 @@ Decides if audio should get quieter with distance linearly, quadratically or logarithmically. - If [code]true[/code], audio plays audio plays when added to scene tree. Default value: [code]false[/code]. + If [code]true[/code] audio plays when added to scene tree. Default value: [code]false[/code]. Bus on which this audio is playing. @@ -300,7 +301,7 @@ The angle in which the audio reaches cameras undampened. - If [code]true[/code], the audio should be dampened according to the direction of the sound. + If [code]true[/code] the audio should be dampened according to the direction of the sound. dampens audio if camera is outside of 'emission_angle_degrees' and 'emission_angle_enabled' is set by this factor, in dB.