View previous topic :: View next topic |
Author |
Message |
zeinguteiw n00b
Joined: 05 Dec 2016 Posts: 4
|
Posted: Wed Dec 14, 2016 4:42 am Post subject: [Solved] Audio only works one program at a time |
|
|
I got my audio working on a fresh install, but only one program can be playing audio at once. Even within programs, for example, if I play a youtube video in firefox I can hear sound fine, but if I open up another tab and try watching another youtube video no sound comes out. My system worked fine on Ubuntu, how can I get different audio streams to mix and not cause issues?
Also, another example, if I play a youtube video with firefox and then try to play a video with mplayer I get the following error:
[AO_ALSA] Playback open error: Device or resource busy
DVB card number must be between 1 and 4
Last edited by zeinguteiw on Thu Dec 15, 2016 5:39 am; edited 1 time in total |
|
Back to top |
|
|
v_andal Guru
Joined: 26 Aug 2008 Posts: 541 Location: Germany
|
Posted: Wed Dec 14, 2016 8:50 am Post subject: |
|
|
Most of the cards now allow only 1 playback at a time. There are some cards that allow more than one, but looks like it is not your case. So, if you want to have multiple applications using audio, then you have to enable "dmix" for ALSA, or install some server like pulseaudio or Jack. On my system I have Intel HDA card (snd_hda_intel driver). To enable dmix I've placed following into my /etc/asound.conf
Quote: |
ctl.!default {
type hw
card 1
}
pcm.!default{
type asym
playback.pcm {
type plug
slave.pcm "dmix:CARD=1,RATE=48000"
}
}
|
My "HDA Intel PCH" is listed as card 1 by "aplay -l", that is why asound.conf references it. In your case it might be different card, so adjust the configuration accordingly. |
|
Back to top |
|
|
zeinguteiw n00b
Joined: 05 Dec 2016 Posts: 4
|
|
Back to top |
|
|
kernelOfTruth Watchman
Joined: 20 Dec 2005 Posts: 6111 Location: Vienna, Austria; Germany; hello world :)
|
Posted: Mon Dec 26, 2016 7:06 pm Post subject: |
|
|
v_andal wrote: | Most of the cards now allow only 1 playback at a time. There are some cards that allow more than one, but looks like it is not your case. So, if you want to have multiple applications using audio, then you have to enable "dmix" for ALSA, or install some server like pulseaudio or Jack. On my system I have Intel HDA card (snd_hda_intel driver). To enable dmix I've placed following into my /etc/asound.conf
Quote: |
ctl.!default {
type hw
card 1
}
pcm.!default{
type asym
playback.pcm {
type plug
slave.pcm "dmix:CARD=1,RATE=48000"
}
}
|
My "HDA Intel PCH" is listed as card 1 by "aplay -l", that is why asound.conf references it. In your case it might be different card, so adjust the configuration accordingly. |
Might try this out once I grow tired of pulseaudio,
*subscribing*
Thanks _________________ https://github.com/kernelOfTruth/ZFS-for-SystemRescueCD/tree/ZFS-for-SysRescCD-4.9.0
https://github.com/kernelOfTruth/pulseaudio-equalizer-ladspa
Hardcore Gentoo Linux user since 2004 |
|
Back to top |
|
|
geol n00b
Joined: 18 Dec 2018 Posts: 11
|
Posted: Tue May 19, 2020 7:44 am Post subject: |
|
|
Hi I encountered exactly the same issue. I will try your solutions tomorrow and will let you know if it works for me. Thanks. |
|
Back to top |
|
|
Anon-E-moose Watchman
Joined: 23 May 2008 Posts: 6098 Location: Dallas area
|
Posted: Tue May 19, 2020 10:02 am Post subject: |
|
|
The only problem with multiple sources and alsa by way of slave, is that it doesn't sound as nice (clear,sharp,etc), since the rate is limited to 48000 which triggers on software mixing. IIRC. _________________ PRIME x570-pro, 3700x, 6.1 zen kernel
gcc 13, profile 17.0 (custom bare multilib), openrc, wayland |
|
Back to top |
|
|
geol n00b
Joined: 18 Dec 2018 Posts: 11
|
Posted: Tue May 19, 2020 2:34 pm Post subject: |
|
|
Anon-E-moose wrote: | The only problem with multiple sources and alsa by way of slave, is that it doesn't sound as nice (clear,sharp,etc), since the rate is limited to 48000 which triggers on software mixing. IIRC. |
Thanks for the reminder! I can confirm that the solution does work. |
|
Back to top |
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
|