-
Notifications
You must be signed in to change notification settings - Fork 2.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Firefox no sound without PulseAudio #34596
Comments
Works for me on
Might tell you what goes wrong when trying to open the ALSA device(s). |
@notramo can you test with a /etc/asound.conf or ~/.asoundrc
then |
Confirm Firefox, ESR and not, work well with Alsa only. Tweaking asound is required with some sound cards |
It seems like nobody is able to reproduce this issue and the issue author is not answering questions. |
@paper42 could you reopen? I looked into this. |
It doesn't print anything. No output in terminal. |
I substituted 1 with 0, and put this snippet in /etc/asound.conf
|
Maybe it can help that Element Desktop doesn't have sound either. |
Sorry, should have mentioned: You have to actually let Firefox try to play audio while running under |
Its not supported upstream and generally works, I don't think we need to debug unsupported audio setups for you, this is most likely related to not using dmix and the alsa hardware device being locked to some random audio stream that opens the device first. |
@Duncaen Could you link where upstream mentions that ALSA is not supported? I thought Cubeb was made for supporting multiple audio systems. |
I tried to open sound files, but playback is stuck at 0:00. |
https://bugzilla.mozilla.org/show_bug.cgi?id=1345661 Audio in firefox is a little more complicated than just the cubeb backend due to sandboxing and having separate content processes. Mozilla disabled alsa support a long time ago and basically said that they don't support it any further, there are still people who afterwards contributed patches to make it work and they landed upstream. But I fully understand why they don't support it, the alsa user experience and the api in general is simply not user friendly and doesn't work out of the box for most users. I would suggest you to use a sound server, like pulse or pipewire, if you still want to use alsa for some reason, look up how to debug libcubeb and how to debug sandbox issues in firefox, both have their own environment variables for more verbose logging. (After you get your basic alsa setup working, I still think this is due to your setup neither supporting software nor hardware mixing and there is simply one random process/program locking the alsa device at a time.) |
In case someone runs into this, I have found a simpler solution.
|
You shouldn't be using alsa-sndio regularly, I wrote it 5 years ago and it doesn't work well, especially not when you need audio/video synchornization and is basically unmaintained. It will never work correctly because the alsa plugin api does not provide functionality to actually get matching buffers negotiated between the alsa plugin and sndiod. Its really not worth the trouble, just use a well supported sound server to avoid unnecessary headaches/troubles. |
I mean if sndio is installed, but not alsa-sndio, then Firefox uses sndio, everything other uses ALSA. |
"Poettering™ sound server suckage" works out of the box for 99% of linux users and they don't have to try to solve their actually broken setup for nearly a year. Comments like this just show why its not worth it to support unsupported setups, you just want the trouble for some weird superiority points. Again, you shouldn't be using alsa-sndio, its not a solution, either you use sndio by using software that supports it or you use sndio only in firefox and basically break everything else that still uses alsa with alsa-sndio. 100% more broken than pulse or pipewire could ever be. |
I emphasize, I don't have
I don't say everyone have to follow this configuration. I left these here for users who want minimalist setup. It's worth trying if someone wants this setup, and if it doesn't work, they can move on to other sound systems. It works for me, so it's possible that it will work for others. I do not recommend it, but if someone likes it, they can try. |
System
Void 5.15.5_1 x86_64-musl GenuineIntel uptodate rFF
happens on also glibc
firefox
Expected behavior
Firefox can play audio even without PulseAudio.
Actual behavior
No web content can play any audio.
Steps to reproduce the behavior
The text was updated successfully, but these errors were encountered: