Rebase against 58e95f72218fa018739c484f172bc236e685d5bb.

[dbghelp-EnumerateLoadedModulesExW]
Removed patch to implement dbghelp.EnumerateLoadedModulesExW (fixed upstream).
This commit is contained in:
Sebastian Lackner
2016-05-19 01:23:36 +02:00
parent 8a2c526e13
commit 16e6b1c3e3
12 changed files with 323 additions and 392 deletions

View File

@@ -1,4 +1,4 @@
From 31e4f44b8a215624ffc771f055ca1012f4c77841 Mon Sep 17 00:00:00 2001
From ed0264f5193ecf9d7724be5de6c9bda17919105f Mon Sep 17 00:00:00 2001
From: Sebastian Lackner <sebastian@fds-team.de>
Date: Sat, 28 Mar 2015 08:18:10 +0100
Subject: dsound: Apply filters before sound is multiplied to speakers.
@@ -11,34 +11,34 @@ Based on a patch by Mark Harmstone.
3 files changed, 77 insertions(+), 32 deletions(-)
diff --git a/dlls/dsound/dsound.c b/dlls/dsound/dsound.c
index cc3feb2..560c1f8 100644
index 64bfbd3..d73610e 100644
--- a/dlls/dsound/dsound.c
+++ b/dlls/dsound/dsound.c
@@ -237,6 +237,7 @@ static ULONG DirectSoundDevice_Release(DirectSoundDevice * device)
@@ -233,6 +233,7 @@ static ULONG DirectSoundDevice_Release(DirectSoundDevice * device)
if(device->volume)
IAudioStreamVolume_Release(device->volume);
+ HeapFree(GetProcessHeap(), 0, device->dsp_buffer);
HeapFree(GetProcessHeap(), 0, device->tmp_buffer);
HeapFree(GetProcessHeap(), 0, device->cp_buffer);
HeapFree(GetProcessHeap(), 0, device->buffer);
RtlDeleteResource(&device->buffer_list_lock);
diff --git a/dlls/dsound/dsound_private.h b/dlls/dsound/dsound_private.h
index 6cfc33e..c6beaea 100644
index 34bab65..f580915 100644
--- a/dlls/dsound/dsound_private.h
+++ b/dlls/dsound/dsound_private.h
@@ -88,8 +88,8 @@ struct DirectSoundDevice
int speaker_num[DS_MAX_CHANNELS];
int num_speakers;
int lfe_channel;
- float *tmp_buffer;
- DWORD tmp_buffer_len;
+ float *tmp_buffer, *dsp_buffer;
+ DWORD tmp_buffer_len, dsp_buffer_len;
- float *tmp_buffer, *cp_buffer;
- DWORD tmp_buffer_len, cp_buffer_len;
+ float *tmp_buffer, *cp_buffer, *dsp_buffer;
+ DWORD tmp_buffer_len, cp_buffer_len, dsp_buffer_len;
DSVOLUMEPAN volpan;
diff --git a/dlls/dsound/mixer.c b/dlls/dsound/mixer.c
index c358385..9a6224e 100644
index a2fd768..db4235d 100644
--- a/dlls/dsound/mixer.c
+++ b/dlls/dsound/mixer.c
@@ -266,23 +266,22 @@ static inline float get_current_sample(const IDirectSoundBufferImpl *dsb,
@@ -93,7 +93,7 @@ index c358385..9a6224e 100644
LONG64 freqAcc_start = *freqAccNum;
LONG64 freqAcc_end = freqAcc_start + count * dsb->freqAdjustNum;
@@ -372,7 +371,7 @@ static UINT cp_fields_resample_hq(IDirectSoundBufferImpl *dsb, UINT count, LONG6
@@ -383,7 +382,7 @@ static UINT cp_fields_resample_hq(IDirectSoundBufferImpl *dsb, UINT count, LONG6
float* cache = &intermediate[channel * required_input + ipos];
for (j = 0; j < fir_used; j++)
sum += fir_copy[j] * cache[j];
@@ -102,7 +102,7 @@ index c358385..9a6224e 100644
}
}
@@ -384,16 +383,17 @@ static UINT cp_fields_resample_hq(IDirectSoundBufferImpl *dsb, UINT count, LONG6
@@ -392,16 +391,17 @@ static UINT cp_fields_resample_hq(IDirectSoundBufferImpl *dsb, UINT count, LONG6
return max_ipos;
}
@@ -124,7 +124,7 @@ index c358385..9a6224e 100644
ipos = dsb->sec_mixpos + adv * dsb->pwfx->nBlockAlign;
if (ipos >= dsb->buflen) {
@@ -423,6 +423,21 @@ static inline DWORD DSOUND_BufPtrDiff(DWORD buflen, DWORD ptr1, DWORD ptr2)
@@ -431,6 +431,21 @@ static inline DWORD DSOUND_BufPtrDiff(DWORD buflen, DWORD ptr1, DWORD ptr2)
return buflen + ptr1 - ptr2;
}
}
@@ -146,7 +146,7 @@ index c358385..9a6224e 100644
/**
* Mix at most the given amount of data into the allocated temporary buffer
* of the given secondary buffer, starting from the dsb's first currently
@@ -438,32 +453,61 @@ static inline DWORD DSOUND_BufPtrDiff(DWORD buflen, DWORD ptr1, DWORD ptr2)
@@ -446,32 +461,61 @@ static inline DWORD DSOUND_BufPtrDiff(DWORD buflen, DWORD ptr1, DWORD ptr2)
*/
static void DSOUND_MixToTemporary(IDirectSoundBufferImpl *dsb, DWORD frames)
{