Home Information Classes Download Usage Mail List Requirements Links Tutorial
00001 /***************************************************/ 00022 /***************************************************/ 00023 00024 #ifndef STK_STIFKARP_H 00025 #define STK_STIFKARP_H 00026 00027 #include "Instrmnt.h" 00028 #include "DelayL.h" 00029 #include "DelayA.h" 00030 #include "OneZero.h" 00031 #include "Noise.h" 00032 #include "BiQuad.h" 00033 00034 class StifKarp : public Instrmnt 00035 { 00036 public: 00038 StifKarp(StkFloat lowestFrequency); 00039 00041 ~StifKarp(); 00042 00044 void clear(); 00045 00047 void setFrequency(StkFloat frequency); 00048 00050 void setStretch(StkFloat stretch); 00051 00053 void setPickupPosition(StkFloat position); 00054 00056 00061 void setBaseLoopGain(StkFloat aGain); 00062 00064 void pluck(StkFloat amplitude); 00065 00067 void noteOn(StkFloat frequency, StkFloat amplitude); 00068 00070 void noteOff(StkFloat amplitude); 00071 00073 StkFloat tick(); 00074 00076 StkFloat *tick(StkFloat *vector, unsigned int vectorSize); 00077 00079 00085 StkFrames& tick( StkFrames& frames, unsigned int channel = 1 ); 00086 00088 void controlChange(int number, StkFloat value); 00089 00090 protected: 00091 DelayA delayLine_; 00092 DelayL combDelay_; 00093 OneZero filter_; 00094 Noise noise_; 00095 BiQuad biquad_[4]; 00096 00097 unsigned long length_; 00098 StkFloat loopGain_; 00099 StkFloat baseLoopGain_; 00100 StkFloat lastFrequency_; 00101 StkFloat lastLength_; 00102 StkFloat stretching_; 00103 StkFloat pluckAmplitude_; 00104 StkFloat pickupPosition_; 00105 00106 }; 00107 00108 #endif
The Synthesis ToolKit in C++ (STK) |
©1995-2004 Perry R. Cook and Gary P. Scavone. All Rights Reserved. |