aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2022-06-16 18:32:59 -0700
committerChris Robinson <[email protected]>2022-06-16 18:32:59 -0700
commit080e2cd16f95ecdd54cbde3b15de6ff022274c66 (patch)
tree6383261357d67d0883efc2a5c02a342266d109c6
parent00dced1c968a249eeef2b112fdb40febf2bc2c7a (diff)
Match exactly 5.1 Rear in WASAPI
So 7.1 and other configurations like it aren't detected as 5.1 Rear despite having side channels.
-rw-r--r--alc/backends/wasapi.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/alc/backends/wasapi.cpp b/alc/backends/wasapi.cpp
index dd928299..9007da1b 100644
--- a/alc/backends/wasapi.cpp
+++ b/alc/backends/wasapi.cpp
@@ -912,7 +912,7 @@ HRESULT WasapiPlayback::resetProxy()
{
const uint32_t chancount{OutputType.Format.nChannels};
const DWORD chanmask{OutputType.dwChannelMask};
- isRear51 = (chancount >= 6 && (chanmask&X51RearMask) == X5DOT1REAR);
+ isRear51 = (chancount == 6 && (chanmask&X51RearMask) == X5DOT1REAR);
}
OutputType.Format.wFormatTag = WAVE_FORMAT_EXTENSIBLE;
@@ -1483,7 +1483,7 @@ HRESULT WasapiCapture::resetProxy()
CoTaskMemFree(wfx);
wfx = nullptr;
- const bool isRear51{InputType.Format.nChannels >= 6
+ const bool isRear51{InputType.Format.nChannels == 6
&& (InputType.dwChannelMask&X51RearMask) == X5DOT1REAR};
// Make sure buffer is at least 100ms in size