diff options
author | Max Hilbrunner <mhilbrunner@users.noreply.github.com> | 2018-05-26 18:22:05 +0200 |
---|---|---|
committer | GitHub <noreply@github.com> | 2018-05-26 18:22:05 +0200 |
commit | 7e8b7a7815788544d9cfacb14e265d10cf832160 (patch) | |
tree | f652668315711faf6560afad51582a0cfa2d7311 /modules | |
parent | 98dd2b3c7951bb7bab5c0aee4ce28970f6523bad (diff) | |
parent | ef74954e6629e20599ef37148236d0f30cb5692b (diff) |
Merge pull request #18379 from ZDDM/18-04-23-audiostream-docs
Fully expose the data variable in AudioStreamSample and AudioStreamOGGVorbis
Diffstat (limited to 'modules')
-rw-r--r-- | modules/stb_vorbis/audio_stream_ogg_vorbis.cpp | 6 | ||||
-rw-r--r-- | modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml | 3 |
2 files changed, 6 insertions, 3 deletions
diff --git a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp index 18ab616826..c95a8ac2dd 100644 --- a/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp +++ b/modules/stb_vorbis/audio_stream_ogg_vorbis.cpp @@ -263,8 +263,8 @@ float AudioStreamOGGVorbis::get_length() const { void AudioStreamOGGVorbis::_bind_methods() { - ClassDB::bind_method(D_METHOD("_set_data", "data"), &AudioStreamOGGVorbis::set_data); - ClassDB::bind_method(D_METHOD("_get_data"), &AudioStreamOGGVorbis::get_data); + ClassDB::bind_method(D_METHOD("set_data", "data"), &AudioStreamOGGVorbis::set_data); + ClassDB::bind_method(D_METHOD("get_data"), &AudioStreamOGGVorbis::get_data); ClassDB::bind_method(D_METHOD("set_loop", "enable"), &AudioStreamOGGVorbis::set_loop); ClassDB::bind_method(D_METHOD("has_loop"), &AudioStreamOGGVorbis::has_loop); @@ -272,7 +272,7 @@ void AudioStreamOGGVorbis::_bind_methods() { ClassDB::bind_method(D_METHOD("set_loop_offset", "seconds"), &AudioStreamOGGVorbis::set_loop_offset); ClassDB::bind_method(D_METHOD("get_loop_offset"), &AudioStreamOGGVorbis::get_loop_offset); - ADD_PROPERTY(PropertyInfo(Variant::POOL_BYTE_ARRAY, "data", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR | PROPERTY_USAGE_INTERNAL), "_set_data", "_get_data"); + ADD_PROPERTY(PropertyInfo(Variant::POOL_BYTE_ARRAY, "data", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_data", "get_data"); ADD_PROPERTY(PropertyInfo(Variant::BOOL, "loop", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_loop", "has_loop"); ADD_PROPERTY(PropertyInfo(Variant::REAL, "loop_offset", PROPERTY_HINT_NONE, "", PROPERTY_USAGE_NOEDITOR), "set_loop_offset", "get_loop_offset"); } diff --git a/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml b/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml index ac95a7197f..e2281babf7 100644 --- a/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml +++ b/modules/stb_vorbis/doc_classes/AudioStreamOGGVorbis.xml @@ -13,6 +13,9 @@ <methods> </methods> <members> + <member name="data" type="PoolByteArray" setter="set_data" getter="get_data"> + Contains the audio data in bytes. + </member> <member name="loop" type="bool" setter="set_loop" getter="has_loop"> </member> <member name="loop_offset" type="float" setter="set_loop_offset" getter="get_loop_offset"> |