Mercurial > hg > svcore
comparison data/model/SparseModel.h @ 838:33fca917c800
Add toDelimitedDataString alternative with frame extents
author | Chris Cannam |
---|---|
date | Wed, 09 Oct 2013 14:47:19 +0100 |
parents | 05ba4bbd2b87 |
children | c2a399f93843 |
comparison
equal
deleted
inserted
replaced
837:1de00ee53be1 | 838:33fca917c800 |
---|---|
151 virtual QString toDelimitedDataString(QString delimiter) const | 151 virtual QString toDelimitedDataString(QString delimiter) const |
152 { | 152 { |
153 QString s; | 153 QString s; |
154 for (PointListConstIterator i = m_points.begin(); i != m_points.end(); ++i) { | 154 for (PointListConstIterator i = m_points.begin(); i != m_points.end(); ++i) { |
155 s += i->toDelimitedDataString(delimiter, m_sampleRate) + "\n"; | 155 s += i->toDelimitedDataString(delimiter, m_sampleRate) + "\n"; |
156 } | |
157 return s; | |
158 } | |
159 | |
160 virtual QString toDelimitedDataString(QString delimiter, size_t f0, size_t f1) const | |
161 { | |
162 QString s; | |
163 for (PointListConstIterator i = m_points.begin(); i != m_points.end(); ++i) { | |
164 if (i->frame >= f0 && i->frame < f1) { | |
165 s += i->toDelimitedDataString(delimiter, m_sampleRate) + "\n"; | |
166 } | |
156 } | 167 } |
157 return s; | 168 return s; |
158 } | 169 } |
159 | 170 |
160 /** | 171 /** |