Mercurial > hg > svgui
changeset 93:05c41701dc6c
* a bit of tidying, and another improvement to cache hit ratio in FFTCache
for peak-frequency spectra
author | Chris Cannam |
---|---|
date | Tue, 09 May 2006 12:13:35 +0000 |
parents | 23d1e37bbfb4 |
children | c7ade7ea3cfe |
files | layer/SpectrogramLayer.cpp layer/TextLayer.cpp |
diffstat | 2 files changed, 1 insertions(+), 14 deletions(-) [+] |
line wrap: on
line diff
--- a/layer/SpectrogramLayer.cpp Mon May 08 16:44:47 2006 +0000 +++ b/layer/SpectrogramLayer.cpp Tue May 09 12:13:35 2006 +0000 @@ -1928,21 +1928,9 @@ for (size_t q = minbin; q < bins; ++q) { -// float f0 = (float(q) * sr) / m_windowSize; -// float f1 = (float(q + 1) * sr) / m_windowSize; - -// float y0 = 0, y1 = 0; - float y0 = yval[q + 1]; float y1 = yval[q]; - -/* - if (m_binDisplay != PeakFrequencies) { - y0 = v->getYForFrequency(f1, minFreq, maxFreq, logarithmic); - y1 = v->getYForFrequency(f0, minFreq, maxFreq, logarithmic); - } -*/ if (m_binDisplay == PeakBins || m_binDisplay == PeakFrequencies) { if (!m_cache->isLocalPeak(s, q)) continue; @@ -1958,7 +1946,6 @@ s < int(m_cache->getWidth()) - 1) { bool steady = false; -// f0 = f1 = calculateFrequency(q, float f = calculateFrequency(q, m_windowSize, increment, @@ -1968,7 +1955,6 @@ steady); y0 = y1 = v->getYForFrequency -// (f0, minFreq, maxFreq, logarithmic); (f, minFreq, maxFreq, logarithmic); }