comparison audioio/AudioCallbackPlaySource.cpp @ 397:f747be6743ab

Debug bits
author Chris Cannam
date Wed, 13 Aug 2014 16:44:50 +0100
parents 1e4fa2007e61
children 7373a8c262ca f7dddea0dbe0
comparison
equal deleted inserted replaced
396:2f54917f1599 397:f747be6743ab
359 void 359 void
360 AudioCallbackPlaySource::clearRingBuffers(bool haveLock, int count) 360 AudioCallbackPlaySource::clearRingBuffers(bool haveLock, int count)
361 { 361 {
362 if (!haveLock) m_mutex.lock(); 362 if (!haveLock) m_mutex.lock();
363 363
364 cerr << "clearRingBuffers" << endl;
365
364 rebuildRangeLists(); 366 rebuildRangeLists();
365 367
366 if (count == 0) { 368 if (count == 0) {
367 if (m_writeBuffers) count = m_writeBuffers->size(); 369 if (m_writeBuffers) count = m_writeBuffers->size();
368 } 370 }
369 371
372 cerr << "current playing frame = " << getCurrentPlayingFrame() << endl;
373
374 cerr << "write buffer fill (before) = " << m_writeBufferFill << endl;
375
370 m_writeBufferFill = getCurrentBufferedFrame(); 376 m_writeBufferFill = getCurrentBufferedFrame();
377
378 cerr << "current buffered frame = " << m_writeBufferFill << endl;
371 379
372 if (m_readBuffers != m_writeBuffers) { 380 if (m_readBuffers != m_writeBuffers) {
373 delete m_writeBuffers; 381 delete m_writeBuffers;
374 } 382 }
375 383