comparison data/model/Dense3DModelPeakCache.cpp @ 552:bbe503e368a9

* Restore peak bins mode in spectrogram
author Chris Cannam
date Thu, 05 Feb 2009 17:46:34 +0000
parents 408e56d30f58
children 59e7fe1b1003
comparison
equal deleted inserted replaced
551:408e56d30f58 552:bbe503e368a9
46 bool 46 bool
47 Dense3DModelPeakCache::isColumnAvailable(size_t column) const 47 Dense3DModelPeakCache::isColumnAvailable(size_t column) const
48 { 48 {
49 if (!m_source) return false; 49 if (!m_source) return false;
50 if (haveColumn(column)) return true; 50 if (haveColumn(column)) return true;
51 for (int i = 0; i < m_resolution; ++i) { 51 for (int i = m_resolution; i > 0; ) {
52 --i;
52 if (!m_source->isColumnAvailable(column * m_resolution + i)) { 53 if (!m_source->isColumnAvailable(column * m_resolution + i)) {
53 return false; 54 return false;
54 } 55 }
55 } 56 }
56 return true; 57 return true;