Mercurial > hg > aimc
annotate branches/carfac_cpp/include/CARFAC.h @ 564:9c4c3675c3f8
* Added class Ear, and moved the CARFAC members AGC CAR IHC into Ear. CARFAC now holds an array of Ear. TBD what is best.
* Moved the files around, and introduced a makefile that builds unittests using GTest. (Note, GTest path is configured in makefile atm.).
- two moronic tests implemented. :)
author | Ulf.Hammarqvist@gmail.com |
---|---|
date | Sun, 20 May 2012 22:36:47 +0000 |
parents | |
children | f3dde307f4b8 |
rev | line source |
---|---|
Ulf@564 | 1 #ifndef CARFAC_H_ |
Ulf@564 | 2 #define CARFAC_H_ |
Ulf@564 | 3 |
Ulf@564 | 4 #include "CAR.h" |
Ulf@564 | 5 #include "IHC.h" |
Ulf@564 | 6 #include "AGC.h" |
Ulf@564 | 7 #include "Ear.h" |
Ulf@564 | 8 #include <vector> |
Ulf@564 | 9 |
Ulf@564 | 10 const double kDefaultFs = 22050; |
Ulf@564 | 11 |
Ulf@564 | 12 class CARFAC{ |
Ulf@564 | 13 public: |
Ulf@564 | 14 CARFAC(int, CAR_parameters*, IHC_parameters*, AGC_parameters*, int); |
Ulf@564 | 15 virtual ~CARFAC(); |
Ulf@564 | 16 static float ERB_Hz(float, float, float); |
Ulf@564 | 17 |
Ulf@564 | 18 float fs_; |
Ulf@564 | 19 |
Ulf@564 | 20 int n_ch_; // these three, push down to ear level? |
Ulf@564 | 21 float max_channels_per_octave_; |
Ulf@564 | 22 FloatArray pole_freqs_; |
Ulf@564 | 23 |
Ulf@564 | 24 int n_ears_; |
Ulf@564 | 25 std::vector<Ear> ears_; |
Ulf@564 | 26 |
Ulf@564 | 27 private: |
Ulf@564 | 28 CARFAC(){}; |
Ulf@564 | 29 |
Ulf@564 | 30 }; |
Ulf@564 | 31 |
Ulf@564 | 32 #endif /* CARFAC_H_ */ |