Added patch to implement support for xaudio2 float formats with more than 2 channels.

This commit is contained in:
Sebastian Lackner 2017-06-25 05:29:33 +02:00
parent 8f35a7629b
commit ff7e264839
3 changed files with 52 additions and 0 deletions

View File

@ -483,6 +483,7 @@ patch_enable_all ()
enable_wtsapi32_WTSQueryUserToken="$1"
enable_wuauserv_Dummy_Service="$1"
enable_wusa_MSU_Package_Installer="$1"
enable_xaudio2_get_al_format="$1"
enable_xinput9_1_0_Parentsrc="$1"
}
@ -1693,6 +1694,9 @@ patch_enable ()
wusa-MSU_Package_Installer)
enable_wusa_MSU_Package_Installer="$2"
;;
xaudio2-get_al_format)
enable_xaudio2_get_al_format="$2"
;;
xinput9_1_0-Parentsrc)
enable_xinput9_1_0_Parentsrc="$2"
;;
@ -9802,6 +9806,21 @@ if test "$enable_wusa_MSU_Package_Installer" -eq 1; then
) >> "$patchlist"
fi
# Patchset xaudio2-get_al_format
# |
# | This patchset fixes the following Wine bugs:
# | * [#42414] Add support for xaudio2 float formats with more than 2 channels
# |
# | Modified files:
# | * dlls/xaudio2_7/xaudio_dll.c
# |
if test "$enable_xaudio2_get_al_format" -eq 1; then
patch_apply xaudio2-get_al_format/0001-xaudio2-Add-support-for-float-formats-with-more-than.patch
(
printf '%s\n' '+ { "Kimmo Myllyvirta", "xaudio2: Add support for float formats with more than 2 channels.", 1 },';
) >> "$patchlist"
fi
# Patchset xinput9_1_0-Parentsrc
# |
# | This patchset fixes the following Wine bugs:

View File

@ -0,0 +1,32 @@
From c39abfe4849d5ff8c6eb9d60c3295d2326100b09 Mon Sep 17 00:00:00 2001
From: Kimmo Myllyvirta <kimmo.myllyvirta@gmail.com>
Date: Sun, 25 Jun 2017 05:14:05 +0200
Subject: xaudio2: Add support for float formats with more than 2 channels.
See http://openal.org/pipermail/openal/2014-December/000287.html.
---
dlls/xaudio2_7/xaudio_dll.c | 8 ++++++++
1 file changed, 8 insertions(+)
diff --git a/dlls/xaudio2_7/xaudio_dll.c b/dlls/xaudio2_7/xaudio_dll.c
index a09162934ef..13f591630fd 100644
--- a/dlls/xaudio2_7/xaudio_dll.c
+++ b/dlls/xaudio2_7/xaudio_dll.c
@@ -499,6 +499,14 @@ static ALenum get_al_format(const WAVEFORMATEX *fmt)
return AL_FORMAT_MONO_FLOAT32;
case 2:
return AL_FORMAT_STEREO_FLOAT32;
+ case 4:
+ return AL_FORMAT_QUAD32;
+ case 6:
+ return AL_FORMAT_51CHN32;
+ case 7:
+ return AL_FORMAT_61CHN32;
+ case 8:
+ return AL_FORMAT_71CHN32;
}
}
}
--
2.13.1

View File

@ -0,0 +1 @@
Fixes: [42414] Add support for xaudio2 float formats with more than 2 channels