Mercurial > hg > qm-dsp
diff dsp/transforms/FFT.h @ 355:3c7338aff6a8
Drop in kissfft to replace the "old" fft, and add tests for newly-supported sizes
author | Chris Cannam <c.cannam@qmul.ac.uk> |
---|---|
date | Tue, 15 Oct 2013 11:38:18 +0100 |
parents | 9c8ee77db9de |
children | a586888bc06c |
line wrap: on
line diff
--- a/dsp/transforms/FFT.h Tue Oct 15 09:39:58 2013 +0100 +++ b/dsp/transforms/FFT.h Tue Oct 15 11:38:18 2013 +0100 @@ -14,8 +14,8 @@ public: /** * Construct an FFT object to carry out complex-to-complex - * transforms of size nsamples. nsamples must be a power of two in - * this implementation. + * transforms of size nsamples. nsamples does not have to be a + * power of two. */ FFT(int nsamples); ~FFT(); @@ -39,7 +39,8 @@ double *realOut, double *imagOut); private: - int m_n; + class D; + D *m_d; }; class FFTReal @@ -47,8 +48,9 @@ public: /** * Construct an FFT object to carry out real-to-complex transforms - * of size nsamples. nsamples must be a power of two in this - * implementation. + * of size nsamples. nsamples does not have to be a power of two, + * but it does have to be even. (A std::invalid_argument exception + * will be thrown if nsamples is odd.) */ FFTReal(int nsamples); ~FFTReal(); @@ -83,11 +85,8 @@ double *realOut); private: - int m_n; - FFT *m_fft; - double *m_r; - double *m_i; - double *m_discard; + class D; + D *m_d; }; #endif