Home   Information   Classes   Download   Usage   Mail List   Requirements   Links   Tutorial


Saxofony.h

00001 /***************************************************/
00036 /***************************************************/
00037 
00038 #ifndef STK_SAXOFONY_H
00039 #define STK_SAXOFONY_H
00040 
00041 #include "Instrmnt.h"
00042 #include "DelayL.h"
00043 #include "ReedTable.h"
00044 #include "OneZero.h"
00045 #include "Envelope.h"
00046 #include "Noise.h"
00047 #include "WaveLoop.h"
00048 
00049 class Saxofony : public Instrmnt
00050 {
00051  public:
00053 
00056   Saxofony(StkFloat lowestFrequency);
00057 
00059   ~Saxofony();
00060 
00062   void clear();
00063 
00065   void setFrequency(StkFloat frequency);
00066 
00068   void setBlowPosition(StkFloat aPosition);
00069 
00071   void startBlowing(StkFloat amplitude, StkFloat rate);
00072 
00074   void stopBlowing(StkFloat rate);
00075 
00077   void noteOn(StkFloat frequency, StkFloat amplitude);
00078 
00080   void noteOff(StkFloat amplitude);
00081 
00083   StkFloat tick();
00084 
00086   StkFloat *tick(StkFloat *vector, unsigned int vectorSize);
00087 
00089 
00095   StkFrames& tick( StkFrames& frames, unsigned int channel = 1 );
00096 
00098   void controlChange(int number, StkFloat value);
00099 
00100  protected:
00101   DelayL    delays_[2];
00102   ReedTable reedTable_;
00103   OneZero   filter_;
00104   Envelope  envelope_;
00105   Noise     noise_;
00106   WaveLoop *vibrato_;
00107   unsigned long length_;
00108   StkFloat outputGain_;
00109   StkFloat noiseGain_;
00110   StkFloat vibratoGain_;
00111   StkFloat position_;
00112 
00113 };
00114 
00115 #endif

The Synthesis ToolKit in C++ (STK)
©1995-2004 Perry R. Cook and Gary P. Scavone. All Rights Reserved.