diff options
author | reduz <reduzio@gmail.com> | 2022-07-21 01:00:58 +0200 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2022-07-23 07:31:17 +0200 |
commit | d1ddee225830b28171de031bd1f1918ced21b38f (patch) | |
tree | 59fbad7454e47cfc0f746842108d3d6e10b83a40 /editor/editor_properties.cpp | |
parent | 976cb7ea9f59813f99e06c4c345c19ff68c2c591 (diff) | |
download | redot-engine-d1ddee225830b28171de031bd1f1918ced21b38f.tar.gz |
Implement BPM support
Based on #62896, only implements the BPM support part.
* Implements BPM support in the AudioStreamOGG/MP3 importers.
* Can select BPM/Bar Size and total beats in a song file, as well as edit looping points.
* Looping is now BPM aware
* Added a special importer UI for configuring this.
* Added a special preview showing the audio waveform as well as the playback position in the resource picker.
* Renamed `AudioStream::instance` to `instantiate` for correctness.
Diffstat (limited to 'editor/editor_properties.cpp')
-rw-r--r-- | editor/editor_properties.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/editor/editor_properties.cpp b/editor/editor_properties.cpp index aaa518362c..dccc51829a 100644 --- a/editor/editor_properties.cpp +++ b/editor/editor_properties.cpp @@ -3517,6 +3517,9 @@ void EditorPropertyResource::setup(Object *p_object, const String &p_path, const shader_picker->set_edited_material(Object::cast_to<ShaderMaterial>(p_object)); resource_picker = shader_picker; connect(SNAME("ready"), callable_mp(this, &EditorPropertyResource::_update_preferred_shader)); + } else if (p_base_type == "AudioStream") { + EditorAudioStreamPicker *astream_picker = memnew(EditorAudioStreamPicker); + resource_picker = astream_picker; } else { resource_picker = memnew(EditorResourcePicker); } |