comparison NoveltyCurveProcessor.cpp @ 36:4010960c659e

* Merge with Chris' changes
author Carl Bussey <c.bussey@se10.qmul.ac.uk>
date Thu, 04 Sep 2014 14:33:36 +0100
parents a824d7d14eb9
children 89af6709f562
comparison
equal deleted inserted replaced
35:c8dd1049b2d3 36:4010960c659e
35 m_pBandBoundaries = new int[m_numberOfBands+1]; 35 m_pBandBoundaries = new int[m_numberOfBands+1];
36 m_pBandBoundaries[0] = 0; 36 m_pBandBoundaries[0] = 0;
37 for (unsigned int band = 1; band < m_numberOfBands; band++){ 37 for (unsigned int band = 1; band < m_numberOfBands; band++){
38 float lowFreq = 500*pow(2.5, (int)band-1); 38 float lowFreq = 500*pow(2.5, (int)band-1);
39 m_pBandBoundaries[band] = m_fftLength*lowFreq/m_samplingFrequency; 39 m_pBandBoundaries[band] = m_fftLength*lowFreq/m_samplingFrequency;
40 if (m_pBandBoundaries[band] > (int)m_blockSize) {
41 m_pBandBoundaries[band] = m_blockSize;
42 }
40 } 43 }
41 m_pBandBoundaries[m_numberOfBands] = m_blockSize; 44 m_pBandBoundaries[m_numberOfBands] = m_blockSize;
42
43 m_pBandSum = new float [m_numberOfBands]; 45 m_pBandSum = new float [m_numberOfBands];
44 } 46 }
45 47
46 //delete space allocated in initialise() 48 //delete space allocated in initialise()
47 void 49 void