[3.x] Fix trim when importing WAV
(cherry picked from commit 5cd47a1984)
This commit is contained in:
committed by
Rémi Verschelde
parent
86fbd1514e
commit
8c1a8d4396
@ -404,7 +404,7 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s
|
|||||||
|
|
||||||
bool trim = p_options["edit/trim"];
|
bool trim = p_options["edit/trim"];
|
||||||
|
|
||||||
if (trim && (loop_mode != AudioStreamSample::LOOP_DISABLED) && format_channels > 0) {
|
if (trim && (loop_mode == AudioStreamSample::LOOP_DISABLED) && format_channels > 0) {
|
||||||
int first = 0;
|
int first = 0;
|
||||||
int last = (frames / format_channels) - 1;
|
int last = (frames / format_channels) - 1;
|
||||||
bool found = false;
|
bool found = false;
|
||||||
|
|||||||
Reference in New Issue
Block a user