FIR filter cache class. More...
#include <CDSPFIRFilter.h>
Static Public Member Functions | |
| static CDSPFIRFilter & | getLPFilter (const double ReqNormFreq, const double ReqTransBand, const double ReqAtten, const EDSPFilterPhaseResponse ReqPhase, const double ReqGain, const double *const AttenCorrs=R8B_NULL) |
| Calculates or returns reference to a previously calculated (cached) low-pass FIR filter. | |
| static int | getObjCount () |
| Returns the number of filters present in the cache now. This value can be monitored for debugging "forgotten" filters. | |
Static Protected Member Functions | |
| static int & | getObjCountStatic () |
| Returns reference to variable containing cache object count. | |
| static CSyncObject & | getStateSync () |
| Returns reference to filter cache sync object. | |
Friends | |
| class | CDSPFIRFilter |
FIR filter cache class.
Class that implements cache for calculated FIR filters. The required FIR filter should be obtained via the getLPFilter() static function.
|
static |
Calculates or returns reference to a previously calculated (cached) low-pass FIR filter.
Note that the real transition band and attenuation achieved by the filter varies with the magnitude of the required attenuation, and are never 100% exact.
| ReqNormFreq | Required normalized frequency, in the range 0 to 1, inclusive. This is the point after which the stop-band spans. |
| ReqTransBand | Required transition band, in percent of the 0 to ReqNormFreq spectral bandwidth, in the range CDSPFIRFilter::getLPMinTransBand() to CDSPFIRFilter::getLPMaxTransBand(), inclusive. The transition band specifies the part of the spectrum between the -3 dB and ReqNormFreq points. The real resulting -3 dB point varies in the range from -3.00 to -3.05 dB, but is generally very close to -3 dB. |
| ReqAtten | Required stop-band attenuation in decibel, in the range CDSPFIRFilter::getLPMinAtten() to CDSPFIRFilter::getLPMaxAtten(), inclusive. Note that the actual stop-band attenuation of the resulting filter may be 0.40-4.46 dB higher. |
| ReqPhase | Required filter's phase response. |
| ReqGain | Required overall filter's gain (1.0 for unity gain). |
| AttenCorrs | Attentuation correction table, to pass to the filter generation function. For internal use. |