From e9e4d4174ba678a8052dccfc74126c34b78aea6f Mon Sep 17 00:00:00 2001 From: Albert Liu <45282415+ggrtk@users.noreply.github.com> Date: Sat, 17 Apr 2021 20:37:49 -0700 Subject: [PATCH] CubebAudioStream: Set CUBEB_STREAM_PREF_PERSIST flag This is required for getting default IAudioClient behavior on the WASAPI backend. --- src/frontend-common/cubeb_audio_stream.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/frontend-common/cubeb_audio_stream.cpp b/src/frontend-common/cubeb_audio_stream.cpp index d0e61748f..efb6a7d61 100644 --- a/src/frontend-common/cubeb_audio_stream.cpp +++ b/src/frontend-common/cubeb_audio_stream.cpp @@ -43,7 +43,7 @@ bool CubebAudioStream::OpenDevice() params.rate = m_output_sample_rate; params.channels = m_channels; params.layout = CUBEB_LAYOUT_UNDEFINED; - params.prefs = CUBEB_STREAM_PREF_NONE; + params.prefs = CUBEB_STREAM_PREF_PERSIST; u32 latency_frames = 0; rv = cubeb_get_min_latency(m_cubeb_context, ¶ms, &latency_frames);