Home   Information   Classes   Download   Usage   Mail List   Requirements   Links   Tutorial


Brass.h

00001 /***************************************************/
00021 /***************************************************/
00022 
00023 #ifndef STK_BRASS_H
00024 #define STK_BRASS_H
00025 
00026 #include "Instrmnt.h"
00027 #include "DelayA.h"
00028 #include "BiQuad.h"
00029 #include "PoleZero.h"
00030 #include "ADSR.h"
00031 #include "WaveLoop.h"
00032 
00033 class Brass: public Instrmnt
00034 {
00035  public:
00037 
00040   Brass(StkFloat lowestFrequency);
00041 
00043   ~Brass();
00044 
00046   void clear();
00047 
00049   void setFrequency(StkFloat frequency);
00050 
00052   void setLip(StkFloat frequency);
00053 
00055   void startBlowing(StkFloat amplitude, StkFloat rate);
00056 
00058   void stopBlowing(StkFloat rate);
00059 
00061   void noteOn(StkFloat frequency, StkFloat amplitude);
00062 
00064   void noteOff(StkFloat amplitude);
00065 
00067   StkFloat tick();
00068 
00070   StkFloat *tick(StkFloat *vector, unsigned int vectorSize);
00071 
00073 
00079   StkFrames& tick( StkFrames& frames, unsigned int channel = 1 );
00080 
00082   void controlChange(int number, StkFloat value);
00083 
00084  protected:  
00085   DelayA   delayLine_;
00086   BiQuad   lipFilter_;
00087   PoleZero dcBlock_;
00088   ADSR     adsr_;
00089   WaveLoop *vibrato_;
00090   unsigned long length_;
00091   StkFloat lipTarget_;
00092   StkFloat slideTarget_;
00093   StkFloat vibratoGain_;
00094   StkFloat maxPressure_;
00095 
00096 };
00097 
00098 #endif

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