Home Information Classes Download Usage Mail List Requirements Links FAQ Tutorial
00001 /***************************************************/ 00018 /***************************************************/ 00019 00020 #ifndef STK_RESONATE_H 00021 #define STK_RESONATE_H 00022 00023 #include "Instrmnt.h" 00024 #include "ADSR.h" 00025 #include "BiQuad.h" 00026 #include "Noise.h" 00027 00028 class Resonate : public Instrmnt 00029 { 00030 public: 00032 Resonate(); 00033 00035 ~Resonate(); 00036 00038 void clear(); 00039 00041 void setResonance(StkFloat frequency, StkFloat radius); 00042 00044 void setNotch(StkFloat frequency, StkFloat radius); 00045 00047 void setEqualGainZeroes(); 00048 00050 void keyOn(); 00051 00053 void keyOff(); 00054 00056 void noteOn(StkFloat frequency, StkFloat amplitude); 00057 00059 void noteOff(StkFloat amplitude); 00060 00062 void controlChange(int number, StkFloat value); 00063 00064 protected: 00065 00066 StkFloat computeSample( void ); 00067 00068 ADSR adsr_; 00069 BiQuad filter_; 00070 Noise noise_; 00071 StkFloat poleFrequency_; 00072 StkFloat poleRadius_; 00073 StkFloat zeroFrequency_; 00074 StkFloat zeroRadius_; 00075 00076 }; 00077 00078 #endif
The Synthesis ToolKit in C++ (STK) |
©1995-2007 Perry R. Cook and Gary P. Scavone. All Rights Reserved. |