From ac4d4fc7318ea402525c30de93cc665bee3b8af1 Mon Sep 17 00:00:00 2001 From: Chris Robinson Date: Sun, 17 Apr 2022 05:27:40 -0700 Subject: Always report ALC_ANY_SOFT for output without contexts Not required, but nicer to be consistent if it's not a meaningful value (e.g. the actual device mode). --- alc/device.cpp | 3 +++ 1 file changed, 3 insertions(+) (limited to 'alc/device.cpp') diff --git a/alc/device.cpp b/alc/device.cpp index 3a9b7380..e06c0d74 100644 --- a/alc/device.cpp +++ b/alc/device.cpp @@ -68,6 +68,9 @@ void ALCdevice::enumerateHrtfs() auto ALCdevice::getOutputMode1() const noexcept -> OutputMode1 { + if(mContexts.load(std::memory_order_relaxed)->empty()) + return OutputMode1::Any; + switch(FmtChans) { case DevFmtMono: return OutputMode1::Mono; -- cgit v1.2.3