diff --git a/stream.cpp b/stream.cpp index 50f7fa94..1225aa64 100644 --- a/stream.cpp +++ b/stream.cpp @@ -141,9 +141,11 @@ void Stream::getPlayerChunk(short* outputBuffer, double outputBufferDacTime, uns int age = Chunk::getAge(getNextPlayerChunk(outputBuffer, framesPerBuffer, correction)) - bufferMs;// + outputBufferDacTime*1000; -// cout << age << "\t"; + long currentTick = getTickCount(); + cout << age << "\t" << msBuffer << "\t" << currentTick - lastTick << "\n"; if (outputBufferDacTime < 1) age += outputBufferDacTime*1000; + lastTick = currentTick; // cout << age << "\t" << outputBufferDacTime*1000 << "\n"; diff --git a/stream.h b/stream.h index 30963d61..ddcd4ab4 100644 --- a/stream.h +++ b/stream.h @@ -27,6 +27,7 @@ private: void updateBuffers(int age); void resetBuffers(); + long lastTick; float sleep; // int correction; Queue> chunks;