Merge branch 'AlexandreRouma:master' into patch-1

This commit is contained in:
Dr. Rubisco 2021-07-27 13:06:17 -04:00 committed by GitHub
commit 5974839515
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -131,12 +131,15 @@ namespace dsp {
level = pow(10, ((10.0f * log10f(level)) - (_CorrectedFallRate * count)) / 10.0f);
if (level < 10e-14) { level = 10e-14; }
float absVal;
for (int i = 0; i < count; i++) {
absVal = fabsf(_in->readBuf[i]);
if (absVal > level) { level = absVal; }
}
volk_32f_s32f_multiply_32f(out.writeBuf, _in->readBuf, 1.0f / level, count);
_in->flush();