GNU Radio 3.7.3 C++ API
|
Fast FFT filter with gr_complex input, gr_complex output and float taps. More...
#include <gnuradio/filter/fft_filter.h>
Public Member Functions | |
fft_filter_ccf (int decimation, const std::vector< float > &taps, int nthreads=1) | |
Construct an FFT filter for complex vectors with the given taps and decimation rate. More... | |
~fft_filter_ccf () | |
int | set_taps (const std::vector< float > &taps) |
Set new taps for the filter. More... | |
void | set_nthreads (int n) |
Set number of threads to use. More... | |
std::vector< float > | taps () const |
Returns the taps. More... | |
unsigned int | ntaps () const |
Returns the number of taps in the filter. More... | |
unsigned int | filtersize () const |
Returns the actual size of the filter. More... | |
int | nthreads () const |
Get number of threads being used. More... | |
int | filter (int nitems, const gr_complex *input, gr_complex *output) |
Perform the filter operation. More... | |
Fast FFT filter with gr_complex input, gr_complex output and float taps.
gr::filter::kernel::fft_filter_ccf::fft_filter_ccf | ( | int | decimation, |
const std::vector< float > & | taps, | ||
int | nthreads = 1 |
||
) |
Construct an FFT filter for complex vectors with the given taps and decimation rate.
This is the basic implementation for performing FFT filter for fast convolution in other blocks for complex vectors (such as fft_filter_ccf).
decimation | The decimation rate of the filter (int) |
taps | The filter taps (complex) |
nthreads | The number of threads for the FFT to use (int) |
gr::filter::kernel::fft_filter_ccf::~fft_filter_ccf | ( | ) |
int gr::filter::kernel::fft_filter_ccf::filter | ( | int | nitems, |
const gr_complex * | input, | ||
gr_complex * | output | ||
) |
Perform the filter operation.
nitems | The number of items to produce |
input | The input vector to be filtered |
output | The result of the filter operation |
unsigned int gr::filter::kernel::fft_filter_ccf::filtersize | ( | ) | const |
Returns the actual size of the filter.
This value could be equal to ntaps, but we ofter build a longer filter to allow us to calculate a more efficient FFT. This value is the actual size of the filters used in the calculation of the overlap-and-save operation.
unsigned int gr::filter::kernel::fft_filter_ccf::ntaps | ( | ) | const |
Returns the number of taps in the filter.
int gr::filter::kernel::fft_filter_ccf::nthreads | ( | ) | const |
Get number of threads being used.
void gr::filter::kernel::fft_filter_ccf::set_nthreads | ( | int | n | ) |
Set number of threads to use.
int gr::filter::kernel::fft_filter_ccf::set_taps | ( | const std::vector< float > & | taps | ) |
Set new taps for the filter.
Sets new taps and resets the class properties to handle different sizes
taps | The filter taps (complex) |
std::vector<float> gr::filter::kernel::fft_filter_ccf::taps | ( | ) | const |
Returns the taps.