VVSDK  1.0
The VVAmbisonic Library
Public Member Functions | Protected Member Functions | Protected Attributes | List of all members
CFilterCoefficients Class Reference

#include <FilterCoefficients.h>

Inheritance diagram for CFilterCoefficients:
CFilterCoefficientsLee

Public Member Functions

 CFilterCoefficients ()
 
virtual ~CFilterCoefficients ()
 
void setCoefficientFileName (const char *sfileName)
 
int getFilterSize (int chan, float sampleRate)
 
void setFilterSize (int chan, float sampleRate, int newFilterSize)
 
void * getCoefficients (int chan, float sampleRate)
 
void setCoefficients (int chan, float sampleRate, float *coefs)
 
int getFilterSizeA (float sampleRate)
 
int getFilterSizeB (float sampleRate)
 
void setFilterSizeA (float sampleRate, int newFilterSize)
 
void setFilterSizeB (float sampleRate, int newFilterSize)
 
void * getCoefficientsA (float sampleRate)
 
void * getCoefficientsB (float sampleRate)
 
void setCoefficientsA (float sampleRate, float *coefs)
 
void setCoefficientsB (float sampleRate, float *coefs)
 

Protected Member Functions

void freeAll ()
 

Protected Attributes

std::map< float, void * > m_mapCoefListA
 
std::map< float, void * > m_mapCoefListB
 
std::map< float, int > m_mapCoefSizesA
 
std::map< float, int > m_mapCoefSizesB
 
std::map< float, void * > m_mapCoefList [MAXCOEFCHAN]
 
std::map< float, int > m_mapCoefSizes [MAXCOEFCHAN]
 
char errorMsg [1024]
 
int errorCode
 

Detailed Description

Filter coefficients container. Can hold any number of channels, each with multiple sampling rates. Can be a few coefficients for IIR filters or long lists for FIR filters.

Constructor & Destructor Documentation

CFilterCoefficients::CFilterCoefficients ( )

Constructor

CFilterCoefficients::~CFilterCoefficients ( )
virtual

Destructor

Member Function Documentation

void CFilterCoefficients::freeAll ( )
protected
void * CFilterCoefficients::getCoefficients ( int  chan,
float  sampleRate 
)

Returns a pointer to the coefficients for the given channel and sampling rate

void * CFilterCoefficients::getCoefficientsA ( float  sampleRate)

Gets the coefficients for channel A for the given sample rate

void * CFilterCoefficients::getCoefficientsB ( float  sampleRate)

Gets the coefficients for channel B for the given sample rate

int CFilterCoefficients::getFilterSize ( int  chan,
float  sampleRate 
)

Returns the number of coefficients for the given channel and sampling rate

int CFilterCoefficients::getFilterSizeA ( float  sampleRate)

Gets the number of coefficients for channel A for the given sample rate

int CFilterCoefficients::getFilterSizeB ( float  sampleRate)

Gets the number of coefficients for channel B for the given sample rate

void CFilterCoefficients::setCoefficientFileName ( const char *  sfileName)

Reads coefficients from a WAV file, using its sample rate

void CFilterCoefficients::setCoefficients ( int  chan,
float  sampleRate,
float *  coefs 
)

Uses the floats pointed to by coefs for the given channel and sampling rate

void CFilterCoefficients::setCoefficientsA ( float  sampleRate,
float *  coefs 
)

Sets the coefficients for channel A for the given sample rate

void CFilterCoefficients::setCoefficientsB ( float  sampleRate,
float *  coefs 
)

Sets the coefficients for channel B for the given sample rate

void CFilterCoefficients::setFilterSize ( int  chan,
float  sampleRate,
int  newFilterSize 
)

Sets the number of coefficients for the given channel and sampling rate

void CFilterCoefficients::setFilterSizeA ( float  sampleRate,
int  newFilterSize 
)

Sets the number of coefficients for channel A for the given sample rate

void CFilterCoefficients::setFilterSizeB ( float  sampleRate,
int  newFilterSize 
)

Sets the number of coefficients for channel B for the given sample rate

Member Data Documentation

int CFilterCoefficients::errorCode
protected
char CFilterCoefficients::errorMsg[1024]
protected
std::map<float, void*> CFilterCoefficients::m_mapCoefList[MAXCOEFCHAN]
protected
std::map<float, void*> CFilterCoefficients::m_mapCoefListA
protected
std::map<float, void*> CFilterCoefficients::m_mapCoefListB
protected
std::map<float, int> CFilterCoefficients::m_mapCoefSizes[MAXCOEFCHAN]
protected
std::map<float, int> CFilterCoefficients::m_mapCoefSizesA
protected
std::map<float, int> CFilterCoefficients::m_mapCoefSizesB
protected

The documentation for this class was generated from the following files: