multimedia over network III: any ALSA-enabled application

ALSA is the Advanced Linux Sound Architecture. The system can forward ALSA sound to PulseAudio.

My config file for ALSA:


pcm.pude {
    type pulse
}
ctl.pude {
    type pulse
}

In this config, I’ve created a pseudo-device “pude” (PulseAudio device) and specified that this device is connected to Pulse Audio.

Now the following should work:


$ mplayer 01_introduction.avi -vo null -ao alsa:device=pude

Unfortunately, on my system, mplayer’s alsa output is broken. I get the following error:


pulse_write: Assertion `pcm->last_size >= (size * pcm->frame_size)' failed.

I don’t know how to fix it.

Testing

The following plays on the local PC through the defaul ALSA device:


$ aplay /usr/share/sounds/*.wav

This plays over network (through PulseAudio):


$ aplay -D pude /usr/share/sounds/*.wav 

Usage

Each application has its own way to specify

* to play through ALSA, and
* use the device “pude”.

For example:

* mplayer: -ao alsa:device=pude
* xine: -A alsa:device=pude

2 Responses to “multimedia over network III: any ALSA-enabled application”

  1. Daniel Says:

    How useful is this, considering what a lot of network bandwidth it would take to send a whole wav across the network in real time?

    Just curious.

  2. billy puertas Says:

    Well, you just need to remember that a CDROM 1X speed was 150KB/s, so, that means that CD quality audio takes less than that. That means that for a lan or wireless network this is little traffic.

    That’s good enough for me.

Leave a Reply