Mercurial > hg > match-vamp
diff src/FeatureExtractor.cpp @ 188:487261a22b18 re-minimise
distance_t * diagonalWeight might not fit in distance_t; use pathcost_t for it. Also remove C-style casts.
author | Chris Cannam |
---|---|
date | Thu, 26 Feb 2015 12:19:17 +0000 |
parents | 6c12db195986 |
children | 2fed1f101172 |
line wrap: on
line diff
--- a/src/FeatureExtractor.cpp Thu Feb 26 10:48:36 2015 +0000 +++ b/src/FeatureExtractor.cpp Thu Feb 26 12:19:17 2015 +0000 @@ -89,7 +89,7 @@ double refFreq = 440.; // See above -- *not* the parameter! double binWidth = double(m_params.sampleRate) / m_params.fftSize; - int crossoverBin = (int)(2 / (pow(2, 1/12.0) - 1)); + int crossoverBin = int(2 / (pow(2, 1/12.0) - 1)); int crossoverMidi = int(log(crossoverBin * binWidth / refFreq)/ log(2.0) * 12 + 69 + 0.5); @@ -133,7 +133,7 @@ { double refFreq = m_params.referenceFrequency; double binWidth = double(m_params.sampleRate) / m_params.fftSize; - int crossoverBin = (int)(1 / (pow(2, 1/12.0) - 1)); + int crossoverBin = int(1 / (pow(2, 1/12.0) - 1)); int i = 0; while (i <= crossoverBin) { double freq = i * binWidth;