Mercurial > hg > qm-dsp
comparison dsp/transforms/FFT.h @ 255:9edaa3ce62e8
* Make MFCC able to accept already-FFT'd input, and simplify API a bit
* Add log power value to MFCC, restore windowing, and avoid some heap allocs
* In HMM, bail out of iteration if loglik hits NaN
author | Chris Cannam <c.cannam@qmul.ac.uk> |
---|---|
date | Fri, 18 Jan 2008 13:24:12 +0000 |
parents | 49844bc8a895 |
children | 6cb2b3cd5356 |
comparison
equal
deleted
inserted
replaced
254:52c1a295d775 | 255:9edaa3ce62e8 |
---|---|
11 #define FFT_H | 11 #define FFT_H |
12 | 12 |
13 class FFT | 13 class FFT |
14 { | 14 { |
15 public: | 15 public: |
16 static void process(unsigned int p_nSamples, bool p_bInverseTransform, | 16 static void process(unsigned int nSamples, bool bInverseTransform, |
17 double *p_lpRealIn, double *p_lpImagIn, | 17 const double *lpRealIn, const double *lpImagIn, |
18 double *p_lpRealOut, double *p_lpImagOut); | 18 double *lpRealOut, double *lpImagOut); |
19 FFT(); | 19 FFT(); |
20 virtual ~FFT(); | 20 virtual ~FFT(); |
21 | 21 |
22 protected: | 22 protected: |
23 static unsigned int reverseBits(unsigned int p_nIndex, unsigned int p_nBits); | 23 static unsigned int reverseBits(unsigned int nIndex, unsigned int nBits); |
24 static unsigned int numberOfBitsNeeded( unsigned int p_nSamples ); | 24 static unsigned int numberOfBitsNeeded( unsigned int nSamples ); |
25 static bool isPowerOfTwo( unsigned int p_nX ); | 25 static bool isPowerOfTwo( unsigned int nX ); |
26 }; | 26 }; |
27 | 27 |
28 #endif | 28 #endif |