Mercurial > hg > svcore
comparison data/model/SparseModel.h @ 1127:815f82508f96 tony-2.0-integration
Back out Matthias's e22bfe8ca248 in the hope that my (earlier but on a different branch, and now merged) fix 882d448c8a6d will do the right thing
author | Chris Cannam |
---|---|
date | Thu, 20 Aug 2015 15:33:13 +0100 |
parents | 39019ce29178 |
children | f80773b5ec96 6b847a59d908 |
comparison
equal
deleted
inserted
replaced
1126:39019ce29178 | 1127:815f82508f96 |
---|---|
179 if (opts & DataExportFillGaps) { | 179 if (opts & DataExportFillGaps) { |
180 return toDelimitedDataStringSubsetFilled(delimiter, opts, f0, f1); | 180 return toDelimitedDataStringSubsetFilled(delimiter, opts, f0, f1); |
181 } else { | 181 } else { |
182 QString s; | 182 QString s; |
183 for (PointListConstIterator i = m_points.begin(); i != m_points.end(); ++i) { | 183 for (PointListConstIterator i = m_points.begin(); i != m_points.end(); ++i) { |
184 if (i->frame >= f0 && i->frame <= f1) { | 184 if (i->frame >= f0 && i->frame < f1) { |
185 s += i->toDelimitedDataString(delimiter, opts, m_sampleRate) + "\n"; | 185 s += i->toDelimitedDataString(delimiter, opts, m_sampleRate) + "\n"; |
186 } | 186 } |
187 } | 187 } |
188 return s; | 188 return s; |
189 } | 189 } |
557 SparseModel<PointType>::getEndFrame() const | 557 SparseModel<PointType>::getEndFrame() const |
558 { | 558 { |
559 QMutexLocker locker(&m_mutex); | 559 QMutexLocker locker(&m_mutex); |
560 sv_frame_t f = 0; | 560 sv_frame_t f = 0; |
561 if (!m_points.empty()) { | 561 if (!m_points.empty()) { |
562 PointListConstIterator i(m_points.end()); | 562 PointListConstIterator i(m_points.end()); |
563 f = (--i)->frame; | 563 f = (--i)->frame; |
564 } | 564 } |
565 if (m_extendTo > f) return m_extendTo; | 565 if (m_extendTo > f) return m_extendTo; |
566 else return f; | 566 else return f; |
567 } | 567 } |
568 | 568 |