c@250: #ifndef _LIB_MFCC_H c@250: #define _LIB_MFCC_H c@250: c@250: #define MFCC 6 c@250: c@250: typedef struct mfcc_t { c@250: c@250: /* Filter bank parameters */ c@250: double lowestFrequency; c@250: int linearFilters; c@250: double linearSpacing; c@250: int logFilters; c@250: double logSpacing; c@250: c@250: /* FFT length */ c@250: int fftSize; c@250: c@250: /* Analysis window length*/ c@250: int windowSize; c@250: c@250: int totalFilters; c@250: c@250: /* Misc. */ c@250: int samplingRate; c@250: int nceps; c@250: c@250: /* MFCC vector */ c@250: double *ceps; c@250: c@250: double **mfccDCTMatrix; c@250: double **mfccFilterWeights; c@250: c@250: /* The analysis window */ c@250: double *window; c@250: c@250: /* For the FFT */ c@250: double* imagIn; // always zero c@250: double* realOut; c@250: double* imagOut; c@250: c@250: /* Set if user want C0 */ c@250: int WANT_C0; c@250: c@250: } mfcc_t; c@250: c@250: extern mfcc_t* init_mfcc(int fftSize, int nceps , int samplingRate, int WANT_C0); c@250: extern int do_mfcc(mfcc_t* mfcc_p, double* frame, int length); c@250: extern void close_mfcc(mfcc_t* mfcc_p); c@250: c@250: #endif c@250: