diff options
author | Juan Linietsky <reduzio@gmail.com> | 2018-01-05 16:27:19 -0300 |
---|---|---|
committer | Juan Linietsky <reduzio@gmail.com> | 2018-01-05 16:28:08 -0300 |
commit | 380ee87e800e44b5e930d784dfb8aeadddf637f3 (patch) | |
tree | 72dcf16bb2e33d8df3d7d3a798b969eaef6b0c4a /editor/import | |
parent | 22cd45b1d52469ef77785ccb25617560ab60ac7b (diff) |
Fixed problem with missing uninitialized last byte on waveform trip, closes #15316
Diffstat (limited to 'editor/import')
-rw-r--r-- | editor/import/resource_importer_wav.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/editor/import/resource_importer_wav.cpp b/editor/import/resource_importer_wav.cpp index b964b96add..f73c7ebfd8 100644 --- a/editor/import/resource_importer_wav.cpp +++ b/editor/import/resource_importer_wav.cpp @@ -387,8 +387,9 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s Vector<float> new_data; new_data.resize((last - first + 1) * format_channels); - for (int i = first * format_channels; i <= last * format_channels; i++) { + for (int i = first * format_channels; i < (last + 1) * format_channels; i++) { new_data[i - first * format_channels] = data[i]; + setc++; } data = new_data; |