#include <avir.h>
Public Member Functions | |
CDSPPeakedCosineLPF (const double aLen2, const double aFreq2, const double aAlpha) | |
template<class T > | |
void | generateLPF (T *op, const double DCGain) |
Public Attributes | |
int | FilterLen |
int | fl2 |
Low-pass filter windowed by Peaked Cosine window function.
This class implements calculation of linear-phase symmetric-odd FIR low-pass filter windowed by the Peaked Cosine window function, for image processing applications.
avir::CDSPPeakedCosineLPF::CDSPPeakedCosineLPF | ( | const double | aLen2, |
const double | aFreq2, | ||
const double | aAlpha | ||
) |
Constructor initalizes *this object.
aLen2 | Half-length (non-truncated) of low-pass filter, in samples (taps). |
aFreq2 | Low-pass filter's corner frequency [0; pi]. |
aAlpha | Peaked Cosine window function Alpha parameter. |
void avir::CDSPPeakedCosineLPF::generateLPF | ( | T * | op, |
const double | DCGain | ||
) |
Function generates a linear-phase low-pass filter windowed by Peaked Cosine window function.
[out] | op | Output buffer, length = FilterLen (fl2 * 2 + 1). |
DCGain | Required gain at DC. The resulting filter will be normalized to achieve this DC gain. If non-positive, no automatic normalization will be performed. |
int avir::CDSPPeakedCosineLPF::FilterLen |
Filter's length in samples (taps).
int avir::CDSPPeakedCosineLPF::fl2 |
Half filter's length, excluding the peak value. This value can be also used as filter's latency in samples (taps).