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.

61 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. /**"AlienWah" Effect*/
  18. class Alienwah:public Effect
  19. {
  20. public:
  21. Alienwah(EffectParams pars);
  22. ~Alienwah();
  23. void out(const Stereo<float *> &smp);
  24. void setpreset(unsigned char npreset);
  25. void changepar(int npar, unsigned char value);
  26. unsigned char getpar(int npar) const;
  27. void cleanup(void);
  28. private:
  29. //Alienwah Parameters
  30. EffectLFO lfo; //lfo-ul Alienwah
  31. unsigned char Pvolume;
  32. unsigned char Pdepth; //the depth of the Alienwah
  33. unsigned char Pfb; //feedback
  34. unsigned char Pdelay;
  35. unsigned char Pphase;
  36. //Control Parameters
  37. void setvolume(unsigned char _Pvolume);
  38. void setdepth(unsigned char _Pdepth);
  39. void setfb(unsigned char _Pfb);
  40. void setdelay(unsigned char _Pdelay);
  41. void setphase(unsigned char _Pphase);
  42. //Internal Values
  43. float fb, depth, phase;
  44. std::complex<float> *oldl, *oldr;
  45. std::complex<float> oldclfol, oldclfor;
  46. int oldk;
  47. };
  48. #endif