Real-valued FFT transform class. More...
#include <CDSPRealFFT.h>
Public Member Functions | |
| void | convertToZP (double *const ap) const |
| Converts the specified forward-transformed block into "zero-phase" form, suitable for use with the multiplyBlocksZP() function. | |
| void | forward (double *const p) const |
| Performs in-place forward FFT. | |
| double | getInvMulConst () const |
| Return a multiplication constant that should be used after inverse transform to obtain a correct value scale. | |
| int | getLen () const |
| Returns the length (the number of real values in a transform) of this FFT object. | |
| int | getLenBits () const |
| Returns the length (the number of real values in a transform) of this FFT object, expressed as Nth power of 2. | |
| void | inverse (double *const p) const |
| Performs in-place inverse FFT. | |
| void | multiplyBlocks (const double *const aip, double *const aop) const |
| Nultiplies two complex-valued data blocks in-place. | |
| void | multiplyBlocks (const double *const aip1, const double *const aip2, double *const aop) const |
| Multiplies two complex-valued data blocks and places result in a new data block. | |
| void | multiplyBlocksZP (const double *const aip, double *const aop) const |
Multiplies two complex-valued data blocks in-place, considering that the aip block contains "zero-phase" response. | |
Friends | |
| class | CDSPRealFFTKeeper |
| class | CPtrKeeper< CDSPRealFFT > |
Real-valued FFT transform class.
Class implements a wrapper for real-valued discrete fast Fourier transform functions. The object of this class can only be obtained via the CDSPRealFFTKeeper class.
Uses functions from the FFT package by: Copyright(C) 1996-2001 Takuya OOURA http://www.kurims.kyoto-u.ac.jp/~ooura/fft.html
Also uses Intel IPP library functions if available (if the R8B_IPP=1 macro was defined). Note that IPP library's FFT functions are 2-3 times more efficient on the modern Intel Core i7-3770K processor than Ooura's functions. It may be worthwhile investing in IPP. Note, that FFT functions take less than 20% of the overall sample rate conversion time. However, when the "power of 2" resampling is used the performance of FFT functions becomes "everything".
| void r8b::CDSPRealFFT::convertToZP | ( | double *const | ap | ) | const |
Converts the specified forward-transformed block into "zero-phase" form, suitable for use with the multiplyBlocksZP() function.
| [in,out] | ap | Block to transform. |
| void r8b::CDSPRealFFT::forward | ( | double *const | p | ) | const |
Performs in-place forward FFT.
| [in,out] | p | Pointer to data block to transform, length should be equal to this object's getLen(). |
| void r8b::CDSPRealFFT::inverse | ( | double *const | p | ) | const |
Performs in-place inverse FFT.
| [in,out] | p | Pointer to data block to transform, length should be equal to this object's getLen(). |
| void r8b::CDSPRealFFT::multiplyBlocks | ( | const double *const | aip, |
| double *const | aop ) const |
Nultiplies two complex-valued data blocks in-place.
Length of both data blocks should be equal to this object's block length. Blocks should have been produced with the forward() function of this object.
| aip | Input data block 1. | |
| [in,out] | aop | Output/input data block 2. |
| void r8b::CDSPRealFFT::multiplyBlocks | ( | const double *const | aip1, |
| const double *const | aip2, | ||
| double *const | aop ) const |
Multiplies two complex-valued data blocks and places result in a new data block.
Length of all data blocks should be equal to this object's block length. Input blocks should have been produced with the forward() function of this object.
| aip1 | Input data block 1. | |
| aip2 | Input data block 2. | |
| [out] | aop | Output data block, should not be equal to aip1 nor aip2. |
| void r8b::CDSPRealFFT::multiplyBlocksZP | ( | const double *const | aip, |
| double *const | aop ) const |
Multiplies two complex-valued data blocks in-place, considering that the aip block contains "zero-phase" response.
Length of both data blocks should be equal to this object's block length. Blocks should have been produced with the forward() function of this object.
| aip | Input data block 1, "zero-phase" response. This block should be first transformed via the convertToZP() function. | |
| [in,out] | aop | Output/input data block 2. |