LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Software (http://www.linuxquestions.org/questions/linux-software-2/)
-   -   Application using sound, blocks access to soundcard for other applications?? (http://www.linuxquestions.org/questions/linux-software-2/application-using-sound-blocks-access-to-soundcard-for-other-applications-282870/)

Erik Plaggenmar 01-27-2005 10:41 AM

Application using sound, blocks access to soundcard for other applications??
 
Hi,
I recently installed Debian on my laptop... Everything is working OK :)
One problem is that my soundcard can only be used by one application at a time, example: i'm playing music in xmms, i can't hear the Gaim sounds, or: i'm playing a movie in MPlayer, when i want to start xmms, xmms says that the soundcard is in use.

The soundcard in my laptop is a nForce onboard sound and i'm using ALSA...

Can anybody help me with this problem or knows any solution, how all the programs can access the soundcard?

Greetz, Erik

hw-tph 01-27-2005 12:05 PM

Either use the Alsa dmix plugin or use a dedicated sound server. Both essentially do the same: They mix audio streams from different programs to one single stream which is sent to the sound card. Sound servers include esound (Enlightenment, Gnome) and arts (KDE).

This is what I use in my ~/.asoundrc on my laptop with nforce3 audio to make ALSA mix it down for me without a sound server:
Code:


pcm.!default {
  type plug
  slave.pcm "dmixer"
}
pcm.dsp0 {
  type plug
  slave.pcm "dmixer"
}
pcm.dmixer {
  type dmix
  ipc_key 1024
 slave {
  pcm "hw:0,0"
  period_time 0
  period_size 1024
 buffer_size 8192
  rate 44100
  }
 bindings {
  0 0
  1 1
  }
}

ctl.dmixer {
  type hw
  card 0
}

Håkan


All times are GMT -5. The time now is 09:00 PM.