From da4697794d37ac027dbcb1879c8b43454cfaba9b Mon Sep 17 00:00:00 2001 From: Cameron Gutman Date: Thu, 13 Sep 2018 13:02:21 -0700 Subject: [PATCH] Increase buffer size for glitch-free playback on macOS --- app/streaming/audio/renderers/qtaud.cpp | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/app/streaming/audio/renderers/qtaud.cpp b/app/streaming/audio/renderers/qtaud.cpp index b7de26fe..ea92ec5c 100644 --- a/app/streaming/audio/renderers/qtaud.cpp +++ b/app/streaming/audio/renderers/qtaud.cpp @@ -29,8 +29,8 @@ bool QtAudioRenderer::prepareForPlayback(const OPUS_MULTISTREAM_CONFIGURATION* o m_AudioOutput = new QAudioOutput(format); - // Buffer 20 ms of audio data - m_AudioOutput->setBufferSize(format.bytesForDuration(20000)); + // Buffer 40 ms of audio data + m_AudioOutput->setBufferSize(format.bytesForDuration(40000)); m_OutputDevice = m_AudioOutput->start(); if (m_OutputDevice == nullptr) {