Re: [PATCH 5/6] winealsa.drv: Don't open the same card on every loop. (resend)
Jeff Cook <jeff(a)deserettechnology.com> writes:
@@ -753,7 +753,7 @@ static int ALSA_ScanDevices(int directhw, char *pcmname = NULL; snd_pcm_t *pcm;
- sprintf(defaultpcmname, "default"); + sprintf(defaultpcmname, "default:%d", card);
We used to do that, but it was changed because it's not correct, cf. bug 10942. -- Alexandre Julliard julliard(a)winehq.org
On Tue, Aug 3, 2010 at 3:57 AM, Alexandre Julliard <julliard(a)winehq.org> wrote:
Jeff Cook <jeff(a)deserettechnology.com> writes:
@@ -753,7 +753,7 @@ static int ALSA_ScanDevices(int directhw, char *pcmname = NULL; snd_pcm_t *pcm;
- sprintf(defaultpcmname, "default"); + sprintf(defaultpcmname, "default:%d", card);
We used to do that, but it was changed because it's not correct, cf. bug 10942.
The thing here is that default:x seems to be the only way to get a card to open compatibly with most setups. I tried opening with plughw:x, hw:x, dmix:x, and any other prefix that was suggested, but default:x was the only thing that worked with my dmix-based ALSA setup. Since dmix is on by default in ALSA, I'd venture that most normal sound setups would break otherwise too. dmix:x worked with dmix, but still behaved oddly (I don't remember exactly what it did), and I reckon that it probably wouldn't work with setups that don't use dmix. Does anyone have a suggested device-opener that is both correct according to API/docs and correct in that it actually works with at least dmix? From Jeff
-- Alexandre Julliard julliard(a)winehq.org
participants (2)
-
Alexandre Julliard -
Jeff Cook