From 2d11a3542cf2968bda5dd6927fa07571f35c90e7 Mon Sep 17 00:00:00 2001 From: David Reid Date: Sun, 9 May 2021 16:16:03 +1000 Subject: [PATCH] PulseAudio: Fix a bug with channel mapping. --- miniaudio.h | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/miniaudio.h b/miniaudio.h index c5870bca..1ddd673d 100644 --- a/miniaudio.h +++ b/miniaudio.h @@ -22913,7 +22913,7 @@ static ma_result ma_device_init__pulse(ma_device* pDevice, const ma_device_confi cmap = *pActualCMap; } - for (iChannel = 0; iChannel < pDevice->capture.internalChannels; ++iChannel) { + for (iChannel = 0; iChannel < pDescriptorCapture->channels; ++iChannel) { pDescriptorCapture->channelMap[iChannel] = ma_channel_position_from_pulse(cmap.map[iChannel]); } @@ -23005,7 +23005,7 @@ static ma_result ma_device_init__pulse(ma_device* pDevice, const ma_device_confi cmap = *pActualCMap; } - for (iChannel = 0; iChannel < pDevice->playback.internalChannels; ++iChannel) { + for (iChannel = 0; iChannel < pDescriptorPlayback->channels; ++iChannel) { pDescriptorPlayback->channelMap[iChannel] = ma_channel_position_from_pulse(cmap.map[iChannel]); } @@ -65002,6 +65002,7 @@ The following miscellaneous changes have also been made. REVISION HISTORY ================ 0.10.36 - TBD + - PulseAudio: Fix a bug with channel mapping. - Silence some warnings when compiling with MA_DEBUG_OUTPUT - Prep work for some upcoming changes to data sources. These changes are still compatible with existing code, however code will need to be updated in preparation for version 0.11 which will