annotate branches/carfac_cpp/include/CAR.h @ 695:2e3672df5698

Simple integration test between CARFAC and SAI. The interface between the two classes is pretty clunky because of the way CARFACOutput stores things. We should work on this, probably by rotating the outer two dimensions of CARFACOutput (i.e. store outputs in containers with sizes n_ears x n_samples x n_channels instead of n_samples x n_ears x n_channels).
author ronw@google.com
date Wed, 26 Jun 2013 23:35:47 +0000
parents 057946a60b91
children
rev   line source
Ulf@564 1 #ifndef CAR_H_
Ulf@564 2 #define CAR_H_
Ulf@564 3
Ulf@564 4 #include "CARFAC_common.h"
Ulf@564 5 #include <cmath>
Ulf@564 6
Ulf@564 7 const double kDefaultErbBreakFreq = 165.3;
Ulf@564 8 const double kDefaultErbQ = 1000/(24.7*4.37);
Ulf@564 9
Ulf@564 10 class CAR_parameters{
Ulf@564 11 public:
Ulf@586 12 CAR_parameters();
Ulf@564 13
Ulf@564 14 float velocity_scale_;
Ulf@564 15 float v_offset_;
Ulf@564 16 float v2_corner_;
Ulf@564 17 float v_damp_max_;
Ulf@564 18 float min_zeta_;
Ulf@564 19 float first_pole_theta_;
Ulf@564 20 float zero_ratio_;
Ulf@564 21 float high_f_damping_compression_;
Ulf@564 22 float erb_per_step_;
Ulf@564 23 float min_pole_hz_;
Ulf@564 24 float erb_break_freq_;
Ulf@564 25 float erb_q_;
Ulf@564 26 };
Ulf@564 27
Ulf@564 28 class CAR_coefficients{
Ulf@564 29 public:
Ulf@590 30 CAR_coefficients(CAR_parameters* car_params_p, float fs,
Ulf@590 31 FloatArray pole_freqs);
Ulf@564 32
Ulf@564 33 FloatArray r1_coeffs_;
Ulf@564 34 FloatArray a0_coeffs_;
Ulf@564 35 FloatArray c0_coeffs_;
Ulf@564 36 FloatArray h_coeffs_;
Ulf@564 37 FloatArray g0_coeffs_;
Ulf@564 38 FloatArray zr_coeffs_;
Ulf@564 39
Ulf@564 40 };
Ulf@564 41
Ulf@564 42 #endif /* CAR_H_ */