Removed extra division by format channels causing sounds to get halved.

(cherry picked from commit e630591aea)
This commit is contained in:
Theis Egeberg 2019-04-11 17:17:33 +02:00 committed by Rémi Verschelde
parent 330c7a2fb4
commit a2cf479f07

View file

@ -409,12 +409,12 @@ Error ResourceImporterWAV::import(const String &p_source_file, const String &p_s
float amp = Math::abs(ampChannelSum / (float)format_channels);
if (!found && amp > limit) {
first = i / format_channels;
first = i;
found = true;
}
if (found && amp > limit) {
last = i / format_channels;
last = i;
}
}