diff options
author | Harald Eilertsen <haraldei@anduin.net> | 2020-07-19 21:31:15 +0200 |
---|---|---|
committer | Harald Eilertsen <haraldei@anduin.net> | 2020-07-19 21:31:15 +0200 |
commit | d94ee6218b6e3f65554c133d9e09044b99f86396 (patch) | |
tree | 2788a56f3550c5eba70c25e0f854b112ccfb190e /plugins/LV2/src/Air/Air.h | |
parent | e3035058fb56b0d507df942b6b89099b2e1a288f (diff) | |
download | airwindows-lv2-port-d94ee6218b6e3f65554c133d9e09044b99f86396.tar.gz airwindows-lv2-port-d94ee6218b6e3f65554c133d9e09044b99f86396.tar.bz2 airwindows-lv2-port-d94ee6218b6e3f65554c133d9e09044b99f86396.zip |
LV2: Add plugin Air
Diffstat (limited to 'plugins/LV2/src/Air/Air.h')
-rw-r--r-- | plugins/LV2/src/Air/Air.h | 93 |
1 files changed, 93 insertions, 0 deletions
diff --git a/plugins/LV2/src/Air/Air.h b/plugins/LV2/src/Air/Air.h new file mode 100644 index 0000000..580650a --- /dev/null +++ b/plugins/LV2/src/Air/Air.h @@ -0,0 +1,93 @@ +#ifndef __Air_H +#define __Air_H + +#include <cstdint> +#include <lv2plugin.h> + +class Air : protected LV2Plugin { +public: + Air(double rate); + + void connect_port(uint32_t port, void * data); + void run(uint32_t num_samples); + + static constexpr const char * URI = "https://www.airwindows.com/air"; + +private: + /* + * These are the original DSP functions from the VST plugin. + * They need to be called from the LV2 plugins `run` function. + */ + void processReplacing(float **in, float **out, VstInt32 samples); + void processDoubleReplacing(double **in, double **out, VstInt32 samples); + + const float * tap22; + const float * tap15; + const float * tap11; + const float * filters_q; + const float * out_level; + const float * dry_wet; + + const float * in[2]; + float * out[2]; + + /* + * Members needed by the processing functions. + */ + double airPrevAL; + double airEvenAL; + double airOddAL; + double airFactorAL; + double airPrevBL; + double airEvenBL; + double airOddBL; + double airFactorBL; + double airPrevCL; + double airEvenCL; + double airOddCL; + double airFactorCL; + double tripletPrevL; + double tripletMidL; + double tripletAL; + double tripletBL; + double tripletCL; + double tripletFactorL; + + double airPrevAR; + double airEvenAR; + double airOddAR; + double airFactorAR; + double airPrevBR; + double airEvenBR; + double airOddBR; + double airFactorBR; + double airPrevCR; + double airEvenCR; + double airOddCR; + double airFactorCR; + double tripletPrevR; + double tripletMidR; + double tripletAR; + double tripletBR; + double tripletCR; + double tripletFactorR; + + bool flipA; + bool flipB; + bool flop; + int count; + + long double fpNShapeL; + long double fpNShapeR; + // + //default stuff + + float A; + float B; + float C; + float D; //parameters. Always 0-1, and we scale/alter them elsewhere. + float E; + float F; +}; + +#endif |