Skip to content

Commit

Permalink
Merge pull request #78048 from AThousandShips/wav_trim_3_x
Browse files Browse the repository at this point in the history
[3.x] Fix trim when importing WAV
  • Loading branch information
akien-mga authored Jun 9, 2023
2 parents cebaa3f + 5cd47a1 commit b3396b0
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion editor/import/resource_importer_wav.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s

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 last = (frames / format_channels) - 1;
bool found = false;
Expand Down

0 comments on commit b3396b0

Please sign in to comment.