Audio plugin host https://kx.studio/carla
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

66 lines
1.6KB

  1. /*
  2. ZynAddSubFX - a software synthesizer
  3. Alienwah.h - "AlienWah" effect
  4. Copyright (C) 2002-2005 Nasca Octavian Paul
  5. Author: Nasca Octavian Paul
  6. This program is free software; you can redistribute it and/or
  7. modify it under the terms of the GNU General Public License
  8. as published by the Free Software Foundation; either version 2
  9. of the License, or (at your option) any later version.
  10. */
  11. #ifndef ALIENWAH_H
  12. #define ALIENWAH_H
  13. #include "Effect.h"
  14. #include "EffectLFO.h"
  15. #include <complex>
  16. #define MAX_ALIENWAH_DELAY 100
  17. namespace zyncarla {
  18. /**"AlienWah" Effect*/
  19. class Alienwah:public Effect
  20. {
  21. public:
  22. Alienwah(EffectParams pars);
  23. ~Alienwah();
  24. void out(const Stereo<float *> &smp);
  25. void setpreset(unsigned char npreset);
  26. void changepar(int npar, unsigned char value);
  27. unsigned char getpar(int npar) const;
  28. void cleanup(void);
  29. static rtosc::Ports ports;
  30. private:
  31. //Alienwah Parameters
  32. EffectLFO lfo; //lfo-ul Alienwah
  33. unsigned char Pvolume;
  34. unsigned char Pdepth; //the depth of the Alienwah
  35. unsigned char Pfb; //feedback
  36. unsigned char Pdelay;
  37. unsigned char Pphase;
  38. //Control Parameters
  39. void setvolume(unsigned char _Pvolume);
  40. void setdepth(unsigned char _Pdepth);
  41. void setfb(unsigned char _Pfb);
  42. void setdelay(unsigned char _Pdelay);
  43. void setphase(unsigned char _Pphase);
  44. //Internal Values
  45. float fb, depth, phase;
  46. std::complex<float> *oldl, *oldr;
  47. std::complex<float> oldclfol, oldclfor;
  48. int oldk;
  49. };
  50. }
  51. #endif