diff options
Diffstat (limited to 'plugins/LV2/src/Acceleration/Acceleration.h')
-rw-r--r-- | plugins/LV2/src/Acceleration/Acceleration.h | 42 |
1 files changed, 40 insertions, 2 deletions
diff --git a/plugins/LV2/src/Acceleration/Acceleration.h b/plugins/LV2/src/Acceleration/Acceleration.h index c277cb9..cfef367 100644 --- a/plugins/LV2/src/Acceleration/Acceleration.h +++ b/plugins/LV2/src/Acceleration/Acceleration.h @@ -1,8 +1,11 @@ -#ifndef __Acceleration_h -#define __Acceleration_h +#ifndef __Acceleration_H +#define __Acceleration_H #include <cstdint> +// Required typa alias for VTS processing funcs. +using VstInt32 = int32_t; + class Acceleration { public: Acceleration(double rate); @@ -11,11 +14,46 @@ public: void run(uint32_t num_samples); private: + void processReplacing(float **in, float **out, VstInt32 samples); + void processDoubleReplacing(double **in, double **out, VstInt32 samples); + + double getSampleRate(); + double rate; const float * limit; const float * drywet; const float * in[2]; float * out[2]; + + // Temp values used by the processing code + double A; // Value of limit when processing called + double B; // Value of dry/wet when processing called + + // To keep state between runs + double ataLastOutL; + double s1L; + double s2L; + double s3L; + double o1L; + double o2L; + double o3L; + double m1L; + double m2L; + double desL; + + double ataLastOutR; + double s1R; + double s2R; + double s3R; + double o1R; + double o2R; + double o3R; + double m1R; + double m2R; + double desR; + + long double fpNShapeL; + long double fpNShapeR; }; #endif |