]> git.sesse.net Git - vlc/blob - modules/audio_filter/spatializer/revmodel.hpp
Use var_Inherit* instead of var_CreateGet*.
[vlc] / modules / audio_filter / spatializer / revmodel.hpp
1 // Reverb model declaration
2 //
3 // Google Summer of Code 2007
4 //
5 // Authors: Biodun Osunkunle <biodun@videolan.org>
6 //
7 // Mentor : Jean-Baptiste Kempf <jb@videolan.org>
8 //
9 // Original written by Jezar at Dreampoint, June 2000
10
11 #ifndef _revmodel_
12 #define _revmodel_
13
14 #include "comb.hpp"
15 #include "allpass.hpp"
16 #include "tuning.h"
17
18 class revmodel
19 {
20 public:
21             revmodel();
22     void    mute();
23     void    processreplace(float *inputL, float *outputL, long numsamples, int skip);
24     void    processmix(float *inputL, float *outputL, long numsamples, int skip);
25     void    setroomsize(float value);
26     float    getroomsize();
27     void    setdamp(float value);
28     float    getdamp();
29     void    setwet(float value);
30     float    getwet();
31     void    setdry(float value);
32     float    getdry();
33     void    setwidth(float value);
34     float    getwidth();
35     void    setmode(float value);
36 private:
37     void    update();
38 private:
39     float    gain;
40     float    roomsize,roomsize1;
41     float    damp,damp1;
42     float    wet,wet1,wet2;
43     float    dry;
44     float    width;
45     float    mode;
46
47 // The following are all declared inline
48 // to remove the need for dynamic allocation
49 // with its subsequent error-checking messiness
50
51 // Comb filters
52     comb    combL[numcombs];
53     comb    combR[numcombs];
54
55     // Allpass filters
56     allpass    allpassL[numallpasses];
57     allpass    allpassR[numallpasses];
58
59     // Buffers for the combs
60     float    bufcombL1[combtuningL1];
61     float    bufcombR1[combtuningR1];
62     float    bufcombL2[combtuningL2];
63     float    bufcombR2[combtuningR2];
64     float    bufcombL3[combtuningL3];
65     float    bufcombR3[combtuningR3];
66     float    bufcombL4[combtuningL4];
67     float    bufcombR4[combtuningR4];
68     float    bufcombL5[combtuningL5];
69     float    bufcombR5[combtuningR5];
70     float    bufcombL6[combtuningL6];
71     float    bufcombR6[combtuningR6];
72     float    bufcombL7[combtuningL7];
73     float    bufcombR7[combtuningR7];
74     float    bufcombL8[combtuningL8];
75     float    bufcombR8[combtuningR8];
76
77     // Buffers for the allpasses
78     float    bufallpassL1[allpasstuningL1];
79     float    bufallpassR1[allpasstuningR1];
80     float    bufallpassL2[allpasstuningL2];
81     float    bufallpassR2[allpasstuningR2];
82     float    bufallpassL3[allpasstuningL3];
83     float    bufallpassR3[allpasstuningR3];
84     float    bufallpassL4[allpasstuningL4];
85     float    bufallpassR4[allpasstuningR4];
86 };
87
88 #endif//_revmodel_
89
90 //ends