Home Information Classes Download Usage Mail List Requirements Links Tutorial

# Plucked.h

    00001 /***************************************************/
    00018 /***************************************************/
    00019
    00020 #if !defined(__PLUCKED_H)
    00021 #define __PLUCKED_H
    00022
    00023 #include "Instrmnt.h"
    00024 #include "DelayA.h"
    00025 #include "OneZero.h"
    00026 #include "OnePole.h"
    00027 #include "Noise.h"
    00028
    00029 class Plucked : public Instrmnt
    00030 {
    00031  public:
    00033   Plucked(MY_FLOAT lowestFrequency);
    00034
    00036   ~Plucked();
    00037
    00039   void clear();
    00040
    00042   virtual void setFrequency(MY_FLOAT frequency);
    00043
    00045   void pluck(MY_FLOAT amplitude);
    00046
    00048   virtual void noteOn(MY_FLOAT frequency, MY_FLOAT amplitude);
    00049
    00051   virtual void noteOff(MY_FLOAT amplitude);
    00052
    00054   virtual MY_FLOAT tick();
    00055
    00056  protected:
    00057   DelayA *delayLine;
    00058   OneZero *loopFilter;
    00059   OnePole *pickFilter;
    00060   Noise *noise;
    00061   long length;
    00062   MY_FLOAT loopGain;
    00063
    00064 };
    00065
    00066 #endif
    00067

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