[pulseaudio-discuss] Can't get pulseaudio to use alsa/dmix?
demonbane at the-love-shack.net
Fri Oct 12 12:32:01 PDT 2007
On Fri, 2007-10-12 at 12:09 -0700, Marc MERLIN wrote:
> On Fri, Oct 12, 2007 at 11:23:08AM -0700, Alex Malinovich wrote:
> > ditching dmix altogether and going with pulse for everything instead.
> > Pulse is much quicker at doing stream mixing in my experience. I
> > recently tried using a combination of pulse and dmix by setting up my
> > front two channels (which show up as a separate device from the rear two
> > through alsa) to be dedicated to pulse, while using dmix to allow
> > multiple apps access to the rear channels, and the delay on the rear was
> > quite noticeable. I then tried setting up dmix for both front and rear
> > without even using pulse at all, and I still ended up getting delays
> > between the front and rear. Made watching a surround-sound movie very...
> > interesting... :)
> I see :)
> But in that case, I can only use apps that can either talk to pulse
> directly, or use esd. I'm not sure I really want that. For instance
> mythfrontend can't work that way, unless I use one of those ugly oss
> wrappers. It seems kind of bad when it speaks alsa natively.
Yes, mythfrontend is unfortunately one of the few programs that won't
(yet) work with the virtual alsa device provided by pulse. There were a
couple of patches submitted a while ago that I believe are in trunk, but
I don't think they've made it into an actual release yet.
> > So I've just been using pulse for everything with my default alsa device
> > in my .asoundrc set to the pulse device and everything works great.
> > There are a couple of apps which don't use the virtual ALSA device
> > properly (notably virtualbox), but almost all the rest are just fine.
> > While mplayer has a native pulse driver now, doing mplayer -ao alsa
> > works just fine as well, going through the virtual alsa device.
> Ah, I see. Do you have a pointer to the alsa config I should be using to get
The wiki on pulseaudio.org has some great info on how to set it up:
The rest of that article is great for getting other pulse-related things
> BTW, here's the output I got from pulseaudio. Does that explain why it takes
> over alsa exclusively? Is it somehow bypassing dmix despite my ocnfig file
> saying the contrary?
> > add-autoload-sink output module-alsa-sink sink_name=output device=dmix
I'm not sure whether you can just use "dmix" as the device when trying
to access alsa like that. To verify you may want to create a dmix entry
in your .asoundrc with a unique name ("testdmix" for example), and then
try loading up module-alsa-sink with device=testdmix.
> module.c: Loaded "module-alsa-sink" (index: #0; argument: "device=hw:0 sink_name=alsa_output.pci_8086_27d8_alsa_playback_0").
It seems pretty clear that module-alsa-sink is NOT, in fact, connecting
a dmix device. For why, see the above paragraph.
Here's an example asoundrc entry that would let you test dmix:
Drop that into your .asoundrc, make sure pulse is not running, and then
try "mplayer -ao alsa:device=dmixer" to make sure it works, and if it
does try updating your pulse config with device=dmixer and see if it
Support Free Software, delete your Windows partition TODAY!
Encrypted mail preferred. You can get my public key from any of the
pgp.net keyservers. Key ID: A6D24837
More information about the pulseaudio-discuss