13
0

Allow to query Biquad coefficients

This commit is contained in:
Robin Gareus 2024-09-10 17:20:05 +02:00
parent a91d515f5d
commit cd6dca6063
Signed by: rgareus
GPG Key ID: A090BCE02CF57F04
2 changed files with 12 additions and 0 deletions

View File

@ -272,6 +272,8 @@ namespace ARDOUR { namespace DSP {
/** reset filter state */
void reset () { _z1 = _z2 = 0.0; }
void coefficients (double& a1, double& a2, double& b0, double& b1, double& b2) const;
private:
void set_vicanek_poles (const double W0, const double Q, const double A = 1.0);
void calc_vicanek (const double W0, double& A0, double& A1, double& A2, double& phi0, double& phi1, double& phi2);

View File

@ -212,6 +212,16 @@ Biquad::configure (double a1, double a2, double b0, double b1, double b2)
_b2 = b2;
}
void
Biquad::coefficients (double& a1, double& a2, double& b0, double& b1, double& b2) const
{
a1 = _a1;
a2 = _a2;
b0 = _b0;
b1 = _b1;
b2 = _b2;
}
void
Biquad::configure (Biquad const& other)
{