Ardour  9.0-pre0-582-g084a23a80d
DecimatorB.h
Go to the documentation of this file.
1 /* -*- c-basic-offset: 4 indent-tabs-mode: nil -*- vi:set ts=8 sts=4 sw=4: */
2 /*
3  QM DSP Library
4 
5  Centre for Digital Music, Queen Mary, University of London.
6 
7  This program is free software; you can redistribute it and/or
8  modify it under the terms of the GNU General Public License as
9  published by the Free Software Foundation; either version 2 of the
10  License, or (at your option) any later version. See the file
11  COPYING included with this distribution for more information.
12 */
13 
14 #ifndef DECIMATORB_H
15 #define DECIMATORB_H
16 
17 #include <vector>
18 
26 {
27 public:
28  void process( const double* src, double* dst );
29  void process( const float* src, float* dst );
30 
39  DecimatorB(int inLength, int decFactor);
40  virtual ~DecimatorB();
41 
42  int getFactor() const { return m_decFactor; }
43 
44 private:
45  void deInitialise();
46  void initialise(int inLength, int decFactor);
47  void doAntiAlias(const double* src, double* dst, int length, int filteridx);
48  void doProcess();
49 
53 
54  std::vector<std::vector<double> > m_o;
55 
56  double m_a[7];
57  double m_b[7];
58 
59  double *m_aaBuffer;
60  double *m_tmpBuffer;
61 };
62 
63 #endif
64 
void deInitialise()
int m_decFactor
Definition: DecimatorB.h:52
void process(const float *src, float *dst)
void doProcess()
DecimatorB(int inLength, int decFactor)
int m_inputLength
Definition: DecimatorB.h:50
void doAntiAlias(const double *src, double *dst, int length, int filteridx)
void process(const double *src, double *dst)
double m_b[7]
Definition: DecimatorB.h:57
double m_a[7]
Definition: DecimatorB.h:56
double * m_aaBuffer
Definition: DecimatorB.h:59
int getFactor() const
Definition: DecimatorB.h:42
double * m_tmpBuffer
Definition: DecimatorB.h:60
int m_outputLength
Definition: DecimatorB.h:51
virtual ~DecimatorB()
void initialise(int inLength, int decFactor)
std::vector< std::vector< double > > m_o
Definition: DecimatorB.h:54
PBD::PropertyDescriptor< timecnt_t > length