Added patch to fix regression caused by passing invalid flag combination to dsound8.

This commit is contained in:
Sebastian Lackner
2016-01-09 22:48:12 +01:00
parent 0f9f441be7
commit a86ca804fc
3 changed files with 62 additions and 0 deletions

View File

@@ -0,0 +1,42 @@
From 51d8680f294c62391912f9e7b47bdb794683e764 Mon Sep 17 00:00:00 2001
From: Michael Stefaniuc <mstefani@redhat.de>
Date: Sat, 9 Jan 2016 22:44:10 +0100
Subject: dmime: Do not pass both DSBCAPS_CTRLPAN and DSBCAPS_CTRL3D to dsound.
---
dlls/dmime/performance.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/dlls/dmime/performance.c b/dlls/dmime/performance.c
index 38f68db..8b5d3e2 100644
--- a/dlls/dmime/performance.c
+++ b/dlls/dmime/performance.c
@@ -1035,7 +1035,7 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_CreateStandardAudioPath(IDire
memset(&desc, 0, sizeof(desc));
desc.dwSize = sizeof(desc);
- desc.dwFlags = DSBCAPS_CTRLFX | DSBCAPS_CTRLPAN | DSBCAPS_CTRLVOLUME | DSBCAPS_GLOBALFOCUS;
+ desc.dwFlags = DSBCAPS_CTRLFX | DSBCAPS_CTRLVOLUME | DSBCAPS_GLOBALFOCUS;
desc.dwBufferBytes = DSBSIZE_MIN;
desc.dwReserved = 0;
desc.lpwfxFormat = &format;
@@ -1046,14 +1046,14 @@ static HRESULT WINAPI IDirectMusicPerformance8Impl_CreateStandardAudioPath(IDire
desc.dwFlags |= DSBCAPS_CTRL3D | DSBCAPS_CTRLFREQUENCY | DSBCAPS_MUTE3DATMAXDISTANCE;
break;
case DMUS_APATH_DYNAMIC_MONO:
- desc.dwFlags |= DSBCAPS_CTRLFREQUENCY;
+ desc.dwFlags |= DSBCAPS_CTRLPAN | DSBCAPS_CTRLFREQUENCY;
break;
case DMUS_APATH_SHARED_STEREOPLUSREVERB:
/* normally we have to create 2 buffers (one for music other for reverb)
* in this case. See msdn
*/
case DMUS_APATH_DYNAMIC_STEREO:
- desc.dwFlags |= DSBCAPS_CTRLFREQUENCY;
+ desc.dwFlags |= DSBCAPS_CTRLPAN | DSBCAPS_CTRLFREQUENCY;
format.nChannels = 2;
format.nBlockAlign *= 2;
format.nAvgBytesPerSec *=2;
--
2.6.4

View File

@@ -0,0 +1 @@
Fixes: [39958] Fix regression caused by passing invalid flag combination to dsound8