Audio FX
 
Loading...
Searching...
No Matches
FFT Class Reference

Handler class to perform the Fast Fourier Transform. More...

#include <fft.h>

Public Member Functions

 FFT (int n)
 Allocate FFT plans and buffers , enabled for multi-threaded or serial use.
 
 ~FFT ()
 Destroy FFT plans and buffers.
 
vector< complex< double > > fft (const vector< double > &v)
 Apply FFT to vector v.
 
vector< double > ifft (const vector< complex< double > > &c)
 Apply IFFT to complex vector c.
 

Static Public Member Functions

static void preInit (int n)
 Associated with constructor. Will only be called once per the scope of the FFT object instantiation. Needed for multi-threading.
 
static void destroyPlan ()
 Destroy plans once all FFT objects are out of scope. Needed for multi-threading.
 

Static Public Attributes

static bool planExists
 

Detailed Description

Handler class to perform the Fast Fourier Transform.

Constructor & Destructor Documentation

◆ FFT()

FFT::FFT ( int n)

Allocate FFT plans and buffers , enabled for multi-threaded or serial use.

Parameters
n-> FFT size

Member Function Documentation

◆ fft()

vector< complex< double > > FFT::fft ( const vector< double > & v)

Apply FFT to vector v.

Parameters
v-> vector

◆ ifft()

vector< double > FFT::ifft ( const vector< complex< double > > & c)

Apply IFFT to complex vector c.

Parameters
c-> complex vector

◆ preInit()

static void FFT::preInit ( int n)
static

Associated with constructor. Will only be called once per the scope of the FFT object instantiation. Needed for multi-threading.

Parameters
n-> FFT size

The documentation for this class was generated from the following file: