~ubuntu-branches/ubuntu/utopic/ardour3/utopic

« back to all changes in this revision

Viewing changes to libs/qm-dsp/dsp/phasevocoder/PhaseVocoder.h

  • Committer: Package Import Robot
  • Author(s): Felipe Sateler
  • Date: 2013-09-21 19:05:02 UTC
  • Revision ID: package-import@ubuntu.com-20130921190502-8gsftrku6jnzhd7v
Tags: upstream-3.4~dfsg
ImportĀ upstreamĀ versionĀ 3.4~dfsg

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
/* -*- c-basic-offset: 4 indent-tabs-mode: nil -*-  vi:set ts=8 sts=4 sw=4: */
 
2
 
 
3
/*
 
4
    QM DSP Library
 
5
 
 
6
    Centre for Digital Music, Queen Mary, University of London.
 
7
    This file 2005-2006 Christian Landone.
 
8
 
 
9
    This program is free software; you can redistribute it and/or
 
10
    modify it under the terms of the GNU General Public License as
 
11
    published by the Free Software Foundation; either version 2 of the
 
12
    License, or (at your option) any later version.  See the file
 
13
    COPYING included with this distribution for more information.
 
14
*/
 
15
 
 
16
#ifndef PHASEVOCODER_H
 
17
#define PHASEVOCODER_H
 
18
 
 
19
class FFTReal;
 
20
 
 
21
class PhaseVocoder  
 
22
{
 
23
public:
 
24
    PhaseVocoder( unsigned int size );
 
25
    virtual ~PhaseVocoder();
 
26
 
 
27
    void process( double* src, double* mag, double* theta);
 
28
 
 
29
protected:
 
30
    void getPhase(unsigned int size, double *theta, double *real, double *imag);
 
31
//    void coreFFT( unsigned int NumSamples, double *RealIn, double* ImagIn, double *RealOut, double *ImagOut);
 
32
    void getMagnitude( unsigned int size, double* mag, double* real, double* imag);
 
33
    void FFTShift( unsigned int size, double* src);
 
34
 
 
35
    unsigned int m_n;
 
36
    FFTReal *m_fft;
 
37
    double *m_imagOut;
 
38
    double *m_realOut;
 
39
 
 
40
};
 
41
 
 
42
#endif