Wine and ALSA

Open forum for end-user questions about Wine. Before asking questions, check out the Wiki as a first step.
Forum Rules
Locked
boxfire
Newbie
Newbie
Posts: 2
Joined: Sat May 24, 2008 1:49 pm

Wine and ALSA

Post by boxfire »

I am having trouble getting wine to work with my sound. When I use winecfg it can not autodetect the right settings, and it only opens a control device, no output device:

Code: Select all

hammertime boxfire # lsof /dev/snd/*
COMMAND    PID    USER   FD   TYPE DEVICE SIZE NODE NAME
winecfg.e 9086 boxfire   10u   CHR 116,32      5684 /dev/snd/controlC1
explorer. 9108 boxfire   10u   CHR 116,32      5684 /dev/snd/controlC1
I have two sound devices

Code: Select all

boxfire@hammertime ~ $ cat /proc/asound/cards
 0 [HDMI           ]: HDA-Intel - HDA ATI HDMI
                      HDA ATI HDMI at 0xfd8fc000 irq 19
 1 [CK804          ]: NFORCE - NVidia CK804
                      NVidia CK804 with ALC850 at irq 22
My .asoundrc:

Code: Select all

boxfire@hammertime ~ $ cat .asoundrc
pcm.dmix8 {
        type dmix
        ipc_key 12354
        ipc_key_add_uid true
        slave {
                pcm "hw:1,0"
                rate 48000
                channels 8
                period_time 0
                period_size 1024
                buffer_time 0
                buffer_size 8192
        }
}

pcm.ch71dup {
        type route
        slave.pcm dmix8
        slave.channels 8
        ttable.0.0 1
        ttable.1.1 1
        ttable.0.2 1
        ttable.1.3 1
        ttable.0.4 1
        ttable.0.5 1
        ttable.0.6 1
        ttable.1.7 1
}

pcm.duplex {
        type asym
        playback.pcm "ch71dup"
        capture.pcm "hw:1,0"
}

pcm.!default {
        type softvol
        slave.pcm "duplex"
        control {
                name "Software Master"
                card 0
        }
}

pcm.dsp "duplex"

pcm.dsp1 "duplex"

My audio output works fine - in fact great. Here is the open files from normal use using the default alsa device:

Code: Select all

boxfire@hammertime ~ $ lsof /dev/dsp* /dev/snd/*
COMMAND  PID    USER   FD   TYPE DEVICE SIZE NODE NAME
mplayer 9188 boxfire  mem    CHR 116,48      5667 /dev/snd/pcmC1D0p
mplayer 9188 boxfire    4r   CHR 116,33      5482 /dev/snd/timer
mplayer 9188 boxfire    5u   CHR 116,48      5667 /dev/snd/pcmC1D0p
mplayer 9188 boxfire    6u   CHR  116,0      5582 /dev/snd/controlC0
If I can I would like to configure it to use the dmix8 device for output. That is 8 channel, alsa will soft mix it so multiple processes can use the audio at once. I have no idea how to manually configure alsa in the registry as it is not documented anywhere. Can anyone help me?

This is on a gentoo x86_64 system with kernel 2.6.24, using wine 1.0-rc2.
boxfire
Newbie
Newbie
Posts: 2
Joined: Sat May 24, 2008 1:49 pm

Post by boxfire »

Update:
If I do

Code: Select all

su -c "rmmod snd_hda_intel"
then run winecfg, it detects sound. winecfg does not work with multiple hardware devices?[/code]
vitamin
Moderator
Moderator
Posts: 6605
Joined: Sat Feb 23, 2008 2:29 pm

Post by vitamin »

boxfire wrote:Update:
If I do

Code: Select all

su -c "rmmod snd_hda_intel"
then run winecfg, it detects sound. winecfg does not work with multiple hardware devices?[/code]
Wine can use only one device at a time.
Locked