summaryrefslogtreecommitdiff
path: root/plugins/ZamEQ2/ZamEQ2Plugin.hpp
diff options
context:
space:
mode:
authorDamien Zammit <damien@zamaudio.com>2014-04-21 19:20:46 +1000
committerDamien Zammit <damien@zamaudio.com>2014-04-21 19:20:46 +1000
commita94ef95fb155a608f85df1ed6154858820fb0b3e (patch)
treed400f295bb103a6f1baaf9651c659328ae98ca46 /plugins/ZamEQ2/ZamEQ2Plugin.hpp
parenta6f1d885fec6080bb9fa8116c61c3393a7cf36fd (diff)
Changed ZamEQ2 DSP to Zolzer model
Signed-off-by: Damien Zammit <damien@zamaudio.com>
Diffstat (limited to 'plugins/ZamEQ2/ZamEQ2Plugin.hpp')
-rw-r--r--plugins/ZamEQ2/ZamEQ2Plugin.hpp26
1 files changed, 9 insertions, 17 deletions
diff --git a/plugins/ZamEQ2/ZamEQ2Plugin.hpp b/plugins/ZamEQ2/ZamEQ2Plugin.hpp
index 4493121..7ff0521 100644
--- a/plugins/ZamEQ2/ZamEQ2Plugin.hpp
+++ b/plugins/ZamEQ2/ZamEQ2Plugin.hpp
@@ -20,6 +20,8 @@
#include "DistrhoPlugin.hpp"
+#define MAX_FILT 4
+
START_NAMESPACE_DISTRHO
// -----------------------------------------------------------------------
@@ -118,27 +120,17 @@ protected:
void d_deactivate() override;
void d_run(float** inputs, float** outputs, uint32_t frames) override;
- void peq(double G0, double G, double GB, double w0, double Dw,
- double *a0, double *a1, double *a2,
- double *b0, double *b1, double *b2, double *gn);
- void lowshelfeq(double G0, double G, double GB,
- double w0, double Dw, double q, double B[], double A[]);
- void highshelfeq(double G0, double G, double GB,
- double w0, double Dw, double q, double B[], double A[]);
+ void peq(int i, int ch, float srate, float fc, float g, float bw);
+ void lowshelf(int i, int ch, float srate, float fc, float g);
+ void highshelf(int i, int ch, float srate, float fc, float g);
+ float run_filter(int i, int ch, double in);
+ double x1[1][MAX_FILT], x2[1][MAX_FILT], y1[1][MAX_FILT], y2[1][MAX_FILT];
+ double b0[1][MAX_FILT], b1[1][MAX_FILT], b2[1][MAX_FILT];
+ double a1[1][MAX_FILT], a2[1][MAX_FILT];
// -------------------------------------------------------------------
private:
float gain1,q1,freq1,gain2,q2,freq2,gainl,freql,gainh,freqh,master,togglepeaks; //parameters
- double x1,x2,y1,y2;
- double x1a,x2a,y1a,y2a;
- double zln1,zln2,zld1,zld2;
- double zhn1,zhn2,zhd1,zhd2;
- double a0x,a1x,a2x,b0x,b1x,b2x,gainx;
- double a0y,a1y,a2y,b0y,b1y,b2y,gainy;
- double Bl[3];
- double Al[3];
- double Bh[3];
- double Ah[3];
};
// -----------------------------------------------------------------------