Home Information Classes Download Usage Mail List Requirements Links FAQ Tutorial
00001 /***************************************************/ 00016 /***************************************************/ 00017 00018 #ifndef STK_DRUMMER_H 00019 #define STK_DRUMMER_H 00020 00021 #include "Instrmnt.h" 00022 #include "FileWvIn.h" 00023 #include "OnePole.h" 00024 00025 const int DRUM_NUMWAVES = 11; 00026 const int DRUM_POLYPHONY = 4; 00027 00028 class Drummer : public Instrmnt 00029 { 00030 public: 00032 00035 Drummer(); 00036 00038 ~Drummer(); 00039 00041 00047 void noteOn(StkFloat instrument, StkFloat amplitude); 00048 00050 void noteOff(StkFloat amplitude); 00051 00052 protected: 00053 00054 StkFloat computeSample( void ); 00055 00056 FileWvIn waves_[DRUM_POLYPHONY]; 00057 OnePole filters_[DRUM_POLYPHONY]; 00058 std::vector<int> soundOrder_; 00059 std::vector<int> soundNumber_; 00060 int nSounding_; 00061 }; 00062 00063 #endif
The Synthesis ToolKit in C++ (STK) |
©1995-2007 Perry R. Cook and Gary P. Scavone. All Rights Reserved. |