diff options
author | Chris Robinson <chris.kcat@gmail.com> | 2022-01-27 02:59:07 -0800 |
---|---|---|
committer | Chris Robinson <chris.kcat@gmail.com> | 2022-01-27 02:59:07 -0800 |
commit | f8ac1ffe805b13c8b1cd2bc4d4a8362cbe1c2cbe (patch) | |
tree | a8a24a3e85f7a8f00cf3947da37e97ab0f42d3f6 /core/bs2b.cpp | |
parent | 1bbea9cd3060ef65a2623f156b4f12ebf62c52fe (diff) |
Get rid of MathDefs
Diffstat (limited to 'core/bs2b.cpp')
-rw-r--r-- | core/bs2b.cpp | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/core/bs2b.cpp b/core/bs2b.cpp index 00207bc0..303bf9bd 100644 --- a/core/bs2b.cpp +++ b/core/bs2b.cpp @@ -27,8 +27,8 @@ #include <cmath> #include <iterator> +#include "alnumbers.h" #include "bs2b.h" -#include "math_defs.h" /* Set up all data. */ @@ -91,11 +91,11 @@ static void init(struct bs2b *bs2b) * $d = 1 / 2 / pi / $fc; * $x = exp(-1 / $d); */ - x = std::exp(-al::MathDefs<float>::Tau() * Fc_lo / static_cast<float>(bs2b->srate)); + x = std::exp(-al::numbers::pi_v<float>*2.0f*Fc_lo/static_cast<float>(bs2b->srate)); bs2b->b1_lo = x; bs2b->a0_lo = G_lo * (1.0f - x) * g; - x = std::exp(-al::MathDefs<float>::Tau() * Fc_hi / static_cast<float>(bs2b->srate)); + x = std::exp(-al::numbers::pi_v<float>*2.0f*Fc_hi/static_cast<float>(bs2b->srate)); bs2b->b1_hi = x; bs2b->a0_hi = (1.0f - G_hi * (1.0f - x)) * g; bs2b->a1_hi = -x * g; |