1 //========================================================= 2 // MusE 3 // Linux Music Editor 4 // $Id: ./plugins/freeverb/revmodel.h $ 5 // 6 // 7 // Written by Jezar at Dreampoint, June 2000 8 // http://www.dreampoint.co.uk 9 // This code is public domain 10 // 11 //========================================================= 12 // Reverb model declaration 13 14 #ifndef _revmodel_ 15 #define _revmodel_ 16 17 #include "comb.h" 18 #include "allpass.h" 19 #include "tuning.h" 20 #include <ladspa.h> 21 22 //--------------------------------------------------------- 23 // Revmodel 24 //--------------------------------------------------------- 25 26 class Revmodel { 27 float gain; 28 float roomsize,roomsize1; 29 float damp,damp1; 30 float width; 31 float mode; 32 33 // Comb filters 34 comb combL[numcombs]; 35 comb combR[numcombs]; 36 37 // Allpass filters 38 allpass allpassL[numallpasses]; 39 allpass allpassR[numallpasses]; 40 41 // Buffers for the combs 42 float bufcombL1[combtuningL1]; 43 float bufcombR1[combtuningR1]; 44 float bufcombL2[combtuningL2]; 45 float bufcombR2[combtuningR2]; 46 float bufcombL3[combtuningL3]; 47 float bufcombR3[combtuningR3]; 48 float bufcombL4[combtuningL4]; 49 float bufcombR4[combtuningR4]; 50 float bufcombL5[combtuningL5]; 51 float bufcombR5[combtuningR5]; 52 float bufcombL6[combtuningL6]; 53 float bufcombR6[combtuningR6]; 54 float bufcombL7[combtuningL7]; 55 float bufcombR7[combtuningR7]; 56 float bufcombL8[combtuningL8]; 57 float bufcombR8[combtuningR8]; 58 59 // Buffers for the allpasses 60 float bufallpassL1[allpasstuningL1]; 61 float bufallpassR1[allpasstuningR1]; 62 float bufallpassL2[allpasstuningL2]; 63 float bufallpassR2[allpasstuningR2]; 64 float bufallpassL3[allpasstuningL3]; 65 float bufallpassR3[allpasstuningR3]; 66 float bufallpassL4[allpasstuningL4]; 67 float bufallpassR4[allpasstuningR4]; 68 void update(); 69 70 public: 71 LADSPA_Data* port[7]; 72 float param[3]; 73 74 Revmodel(); 75 void processmix(long numsamples); 76 void processreplace(long numsamples); 77 void setroomsize(float value); 78 float getroomsize(); 79 void setdamp(float value); 80 void setwidth(float value); 81 void setmode(float value); 82 float getmode(); 83 void activate(); 84 }; 85 86 #endif 87