annotate FIRFilter.h @ 31:f795b84c1ff2
This include change seems necessary for my compiler
author |
Chris Cannam |
date |
Thu, 04 Sep 2014 10:08:09 +0100 |
parents |
de7213b35755 |
children |
4cf2d163127b |
rev |
line source |
c@0
|
1 //
|
c@0
|
2 // FIRFilter.h
|
c@0
|
3 // Tempogram
|
c@0
|
4 //
|
c@0
|
5 // Created by Carl Bussey on 25/06/2014.
|
c@0
|
6 // Copyright (c) 2014 Carl Bussey. All rights reserved.
|
c@0
|
7 //
|
c@0
|
8
|
c@0
|
9 #ifndef __Tempogram__FIRFilter__
|
c@0
|
10 #define __Tempogram__FIRFilter__
|
c@0
|
11
|
c@7
|
12 #include <cmath>
|
c@7
|
13 #include <vamp-sdk/FFT.h>
|
c@7
|
14 #include <assert.h>
|
c@15
|
15 #include <iostream>
|
c@7
|
16
|
c@0
|
17 class FIRFilter{
|
c@0
|
18 public:
|
c@15
|
19 enum OutputTypeArgument{
|
c@15
|
20 first = 0,
|
c@15
|
21 middle,
|
c@15
|
22 all
|
c@15
|
23 };
|
c@15
|
24
|
c@13
|
25 FIRFilter(const size_t &lengthInput, const size_t &numberOfCoefficients);
|
c@0
|
26 ~FIRFilter();
|
c@15
|
27 void process(const float *pInput, const float *pCoefficients, float * pOutput, OutputTypeArgument outputType = first);
|
c@0
|
28 private:
|
c@13
|
29 size_t m_lengthInput;
|
c@13
|
30 size_t m_numberOfCoefficients;
|
c@20
|
31 size_t m_lengthFIRFFT;
|
c@0
|
32
|
c@13
|
33 double *m_pFftInput;
|
c@13
|
34 double *m_pFftCoefficients;
|
c@13
|
35 double *m_pFftReal1;
|
c@13
|
36 double *m_pFftImag1;
|
c@13
|
37 double *m_pFftReal2;
|
c@13
|
38 double *m_pFftImag2;
|
c@13
|
39 double *m_pFftFilteredReal;
|
c@13
|
40 double *m_pFftFilteredImag;
|
c@13
|
41 double *m_pFftOutputReal;
|
c@13
|
42 double *m_pFftOutputImag;
|
c@0
|
43
|
c@0
|
44 void initialise();
|
c@0
|
45 void cleanup();
|
c@0
|
46 };
|
c@0
|
47
|
c@0
|
48 #endif /* defined(__Tempogram__FIRFilter__) */
|