stream: Use expf for floats

This commit is contained in:
MerryMage
2018-09-08 16:22:35 +01:00
parent 9cd79c25ed
commit 32a51859fa

View File

@@ -64,7 +64,7 @@ static void VolumeAdjustSamples(std::vector<s16>& samples) {
}
// Implementation of a volume slider with a dynamic range of 60 dB
const float volume_scale_factor{std::exp(6.90775f * volume) * 0.001f};
const float volume_scale_factor{std::expf(6.90775f * volume) * 0.001f};
for (auto& sample : samples) {
sample = static_cast<s16>(sample * volume_scale_factor);
}