Maarten,
let me apologize for barely taking the time to look at the extra patches
you write outside of the main git tree. I hope other people find more time
to try them out with real apps and report on their findings.
Here are a few comments of mine on your winealsa rewrite (beside bug #22261, comment #6).
- It's been a pleasure to hear mciwave+winealsa open multiple devices concurrently
with dmix mixing all playing sounds thanks to this rewrite.
- wodNotifyDoneList is called from within a critical section in wodTick().
This may break havoc with DCB_FUNCTION callbacks, as the driver
does not appear to be re-entrant.
EnterCriticalSection offers no protection from within the same thread.
Some apps are known to call waveOutClose() from within the DONE callback.
Of course you may delegate this issue to a solution to bug #3930. I'd be curious
if you have any ideas about how to delay notification to a later point
in time, "until it is safe to do" -- native appears to delay as well.
- You may wish to look into bug #22880.
Lemmix is a small (143KB) downloadable application that opens two waveout devices.
It plays both music and sound effects on Mac OS using the winecoreaudio
driver, but fails to do so with your ALSA driver, although both devices open
and WINEDEBUG=+wave shows calls to waveOutWrite. I could not figure out
what goes wrong.
- I've seen old apps ask for ~7000 samples per second.
Your limit of 8000 is too high.
Here's a patch to use DSBFREQUENCY_* like the other devices do.
Lemmix needs it (although I did not investigate why the msacm/pcmconverter
did not kick in and resample to a higher frequency).
>From 54224dbf35354036934d7791acafe0353cbef7bc Mon Sep 17 00:00:00 2001
From: =?utf-8?q?J=C3=B6rg=20H=C3=B6hle?= <hoehle(a)users.sourceforge.net>
Date: Sat, 5 Mar 2011 19:28:00 +0100
Subject: winealsa: Use DSBFREQUENCY_* as lower and upper bounds.
---
dlls/winealsa.drv/waveout.c | 2 +-
1 files changed, 1 insertions(+), 1 deletions(-)
diff --git a/dlls/winealsa.drv/waveout.c b/dlls/winealsa.drv/waveout.c
index 23560cc..b15164b 100644
--- a/dlls/winealsa.drv/waveout.c
+++ b/dlls/winealsa.drv/waveout.c
@@ -225,7 +225,7 @@ static DWORD wodGetDevCaps(waveimpl *dev, LPWAVEOUTCAPSW lpCaps, DWORD dwSize) {
static snd_pcm_format_t get_format(WAVEFORMATEX *wfx) {
WAVEFORMATEXTENSIBLE *wfe = (WAVEFORMATEXTENSIBLE *)wfx;
- if (!wfx->nChannels || wfx->nSamplesPerSec < 8000 || wfx->nSamplesPerSec > 192000)
+ if (!wfx->nChannels || wfx->nSamplesPerSec < DSBFREQUENCY_MIN || wfx->nSamplesPerSec > DSBFREQUENCY_MAX)
return SND_PCM_FORMAT_UNKNOWN;
if (wfx->wFormatTag == WAVE_FORMAT_PCM) {
--
1.5.6.3
Regards,
Jörg Höhle