diff FIRFilter.h @ 0:31d2a7e07786

Moved all to folder "tempogram".
author Carl Bussey <c.bussey@se10.qmul.ac.uk>
date Mon, 07 Jul 2014 10:08:14 +0100
parents
children 21147df9cb2d
line wrap: on
line diff
--- /dev/null	Thu Jan 01 00:00:00 1970 +0000
+++ b/FIRFilter.h	Mon Jul 07 10:08:14 2014 +0100
@@ -0,0 +1,37 @@
+//
+//  FIRFilter.h
+//  Tempogram
+//
+//  Created by Carl Bussey on 25/06/2014.
+//  Copyright (c) 2014 Carl Bussey. All rights reserved.
+//
+
+#ifndef __Tempogram__FIRFilter__
+#define __Tempogram__FIRFilter__
+
+class FIRFilter{
+public:
+    FIRFilter(const unsigned int lengthInput, const unsigned int numberOfCoefficients);
+    ~FIRFilter();
+    void process(const float *input, const float *coefficients, float *output);
+private:
+    unsigned int _lengthInput;
+    unsigned int _numberOfCoefficients;
+    unsigned int _lengthFIRFFT;
+    
+    double *fftInput;
+    double *fftCoefficients;
+    double *fftReal1;
+    double *fftImag1;
+    double *fftReal2;
+    double *fftImag2;
+    double *fftFilteredReal;
+    double *fftFilteredImag;
+    double *fftOutputReal;
+    double *fftOutputImag;
+    
+    void initialise();
+    void cleanup();
+};
+
+#endif /* defined(__Tempogram__FIRFilter__) */