The Open Master Hearing Aid (openMHA)
openMHA
Open community platform for hearing aid algorithm research
|
FFT based FIR filter implementation. More...
Public Member Functions | |
fftfilter_t (unsigned int fragsize, unsigned int channels, unsigned int fftlen) | |
Constructor. More... | |
~fftfilter_t () | |
void | update_coeffs (const mha_wave_t *pwIRS) |
Update the set of coefficients. More... | |
void | filter (const mha_wave_t *pwIn, mha_wave_t **ppwOut, const mha_wave_t *pwIRS) |
Apply filter with changing coefficients to a waveform fragment. More... | |
void | filter (const mha_wave_t *pwIn, mha_wave_t **ppwOut) |
Apply filter to waveform fragment, without changing the coefficients. More... | |
void | filter (const mha_wave_t *pwIn, mha_wave_t **ppwOut, const mha_spec_t *psWeights) |
Apply filter with changing coefficients to a waveform fragment. More... | |
Private Attributes | |
unsigned int | fragsize |
unsigned int | channels |
unsigned int | fftlen |
MHASignal::waveform_t | wInput_fft |
mha_wave_t | wInput |
MHASignal::waveform_t | wOutput_fft |
mha_wave_t | wOutput |
MHASignal::spectrum_t | sInput |
MHASignal::spectrum_t | sWeights |
MHASignal::waveform_t | wIRS_fft |
mha_fft_t | fft |
FFT based FIR filter implementation.
The maximal number of coefficients can be FFT length - fragsize + 1.
MHAFilter::fftfilter_t::fftfilter_t | ( | unsigned int | fragsize, |
unsigned int | channels, | ||
unsigned int | fftlen | ||
) |
Constructor.
fragsize | Number of frames expected in input signal (each cycle). |
channels | Number of channels expected in input signal. |
fftlen | FFT length of filter. |
MHAFilter::fftfilter_t::~fftfilter_t | ( | ) |
void MHAFilter::fftfilter_t::update_coeffs | ( | const mha_wave_t * | pwIRS | ) |
Update the set of coefficients.
pwIRS | Coefficients structure |
void MHAFilter::fftfilter_t::filter | ( | const mha_wave_t * | pwIn, |
mha_wave_t ** | ppwOut, | ||
const mha_wave_t * | pwIRS | ||
) |
Apply filter with changing coefficients to a waveform fragment.
pwIn | Input signal pointer. |
ppwOut | Pointer to output signal pointer, will be set to a valid signal. |
pwIRS | Pointer to FIR coefficients structure. |
void MHAFilter::fftfilter_t::filter | ( | const mha_wave_t * | pwIn, |
mha_wave_t ** | ppwOut | ||
) |
Apply filter to waveform fragment, without changing the coefficients.
pwIn | Input signal pointer. |
ppwOut | Pointer to output signal pointer, will be set to a valid signal |
void MHAFilter::fftfilter_t::filter | ( | const mha_wave_t * | pwIn, |
mha_wave_t ** | ppwOut, | ||
const mha_spec_t * | psWeights | ||
) |
Apply filter with changing coefficients to a waveform fragment.
pwIn | Input signal pointer. |
ppwOut | Pointer to output signal pointer, will be set to a valid signal. |
psWeights | Pointer to filter weights structure. |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |
|
private |