Mercurial > hg > svapp
comparison audioio/AudioCallbackPlaySource.h @ 4:5865094175ea
* Fix update and play limits for play-selection mode when not looping
* Fix playback in loop mode when no selection -- but the GUI update for
this is still wrong on the flyback
* Various fixes and improvements to making selections, particularly during
playback
* Draw selection under non-opaque non-scrollable layers, so as to improve
cacheing
* Show selection limits as text when drawing selection
* Allow user to find missing audio files when loading session
* Cross-fade selections when in play-selection mode -- mostly. We don't
cross-fade on a processing block boundary, and unfortunately with short
selections the selection boundary is quite likely to coincide with a block
boundary.
author | Chris Cannam |
---|---|
date | Wed, 25 Jan 2006 17:46:28 +0000 |
parents | 75c3ea1c3a32 |
children | f3d777b693f7 |
comparison
equal
deleted
inserted
replaced
3:75c3ea1c3a32 | 4:5865094175ea |
---|---|
162 void setSlowdownFactor(size_t factor); | 162 void setSlowdownFactor(size_t factor); |
163 | 163 |
164 signals: | 164 signals: |
165 void modelReplaced(); | 165 void modelReplaced(); |
166 | 166 |
167 void playStatusChanged(bool isPlaying); | |
168 | |
167 /// Just a warning | 169 /// Just a warning |
168 void sampleRateMismatch(size_t requested, size_t available); | 170 void sampleRateMismatch(size_t requested, size_t available); |
169 | 171 |
170 protected slots: | 172 protected slots: |
171 void selectionChanged(); | 173 void selectionChanged(); |
184 size_t m_targetSampleRate; | 186 size_t m_targetSampleRate; |
185 size_t m_playLatency; | 187 size_t m_playLatency; |
186 bool m_playing; | 188 bool m_playing; |
187 bool m_exiting; | 189 bool m_exiting; |
188 size_t m_bufferedToFrame; | 190 size_t m_bufferedToFrame; |
191 size_t m_lastModelEndFrame; | |
189 static const size_t m_ringBufferSize; | 192 static const size_t m_ringBufferSize; |
190 float m_outputLeft; | 193 float m_outputLeft; |
191 float m_outputRight; | 194 float m_outputRight; |
192 | 195 |
193 RingBuffer<float> &getRingBuffer(size_t c) { | 196 RingBuffer<float> &getRingBuffer(size_t c) { |
220 | 223 |
221 size_t m_slowdownCounter; | 224 size_t m_slowdownCounter; |
222 TimeStretcherData *m_timeStretcher; | 225 TimeStretcherData *m_timeStretcher; |
223 Scavenger<TimeStretcherData> m_timeStretcherScavenger; | 226 Scavenger<TimeStretcherData> m_timeStretcherScavenger; |
224 | 227 |
225 void fillBuffers(); // Called from fill thread, m_playing true, mutex held | 228 // Called from fill thread, m_playing true, mutex held |
229 void fillBuffers(); | |
230 | |
231 // Called from fillBuffers | |
226 bool mixModels(size_t &frame, size_t count, float **buffers); | 232 bool mixModels(size_t &frame, size_t count, float **buffers); |
227 | 233 |
228 class AudioCallbackPlaySourceFillThread : public QThread | 234 class AudioCallbackPlaySourceFillThread : public QThread |
229 { | 235 { |
230 public: | 236 public: |