23 #if defined(_MSC_VER) || defined(__MINGW32__)    24 #define bzero(b,len) (memset((b), '\0', (len)), (void) 0)    39     std::cout<<
"Bank Count "<<
bankCount<<std::endl;
   106         std::cerr<<
"AudioMasker::FBMalloc : filter bank malloc error initial"<<std::endl;
   113                 std::cerr<<
"AudioMasker::FBMalloc : filter bank malloc error secondary"<<std::endl;
   120     if (!(
powOutput=
new double*[bankCount])) {
   121         std::cerr<<
"AudioMasker::FBMalloc : filter bank malloc error initial"<<std::endl;
   128             if (!(
powOutput[i]=
new double[(
int)ceil((
double)
fs/2.0)])) {
   129                 std::cerr<<
"AudioMasker::FBMalloc : filter bank malloc error secondary"<<std::endl;
   136         std::cerr<<
"AudioMasker::FBMalloc : input malloc error"<<std::endl;
   149         std::cerr<<
"AudioMasker::FBMalloc : pfb malloc error"<<std::endl;
   156         std::cerr<<
"AudioMasker::FBMalloc : fftData malloc error"<<std::endl;
   162         std::cerr<<
"AudioMasker::FBMalloc : fft malloc error"<<std::endl;
   180     for (
int i=0; i<sCount; i++) 
   181         input[i]=(
double)Input[i];
   196     for (
int i=0; i<sCount; i++) 
   206         if (freq>=
pfb->
ef[i]) {
   211     std::cerr <<
"AudioMasker::findThreshold : freq !=> gtfb->edgeFreq["<<
bankCount-1<<
"] returning 0"<<std::endl;
   226     int halfFS=(int)
rint(
fs/2.0);
   229         for (
int j=0; j<halfFS; j++) {
 RealFFTData * fftData
The FFT data. 
void FBDeMalloc(void)
Filter bank output matrix memory de-allocation. 
double * cf
The filter centre frequencies. 
int bankCount
The filter bank count. 
void setCFreq(int which, double value)
double * input
Filter bank input. 
#define DEFAULT_SAMPLECOUNT
void exciteTerhardt(double **filterBankOutput, int sampleCount)
double * ef
The filter edge frequencies. 
void FBMalloc(void)
Filter bank output matrix memory allocation. 
double * mask
The audio mask. 
int compPowerSpec()
This function computes the power spectrum and returns the max bin. 
int sampleCount
The sample count. 
class RealFFTData controls and manipulates fft data 
double ** powOutput
Filter bank output power. 
int sqrtPowerSpec()
This function computes the square root of the power spectrum and returns the max bin. 
#define DEFAULT_SAMPLEFREQ
double ** output
Filter bank output. 
fftw_real * power_spectrum
double findThreshold(double freq)
void fwdTransform()
Forward transform the data (in to out) 
fftw_real * in
the input, output and power_spectrum arrays 
void process(void)
Process the transformation. 
DepUKFB * pfb
roex filters 
AudioMasker(void)
Audio masker constructor - allowing specification of fs and sub-band count later. ...
void excite(short int *Input, int sCount)
class RealFFT controls fftw plans and executes fwd/inv transforms 
~AudioMasker(void)
Audio masker deconstructor. 
#define fftw_real
use double by default