diff --git a/projects/examples/duplex.cpp b/projects/examples/duplex.cpp index d7ffbb8..696dfd8 100644 --- a/projects/examples/duplex.cpp +++ b/projects/examples/duplex.cpp @@ -104,6 +104,7 @@ int main(int argc, char *argv[]) RtAudio::StreamOptions options; //options.flags |= RTAUDIO_NONINTERLEAVED; + bufferBytes = bufferFrames * channels * sizeof( MY_TYPE ); try { adac.openStream( &oParams, &iParams, FORMAT, fs, &bufferFrames, &inout, (void *)&bufferBytes, &options ); } @@ -112,7 +113,7 @@ int main(int argc, char *argv[]) exit( 1 ); } - bufferBytes = bufferFrames * channels * sizeof( MY_TYPE ); + // Test RtAudio functionality for reporting latency. std::cout << "\nStream latency = " << adac.getStreamLatency() << " frames" << std::endl;