6 ms·
> 6. PulseAudio continues to be the answer to the question nobody asked. 1. How do I change the output destination for audio from typical desktop/consumer ap
by PaulDavisThe1st 5y ago
> 6. PulseAudio continues to be the answer to the question nobody asked.
1. How do I change the output destination for audio from typical desktop/consumer apps without building it into ever such app?
2. How do I deliver audio across a network?
3. How do I use bluetooth audio devices that (were) not yet supported by the ALSA stack?
4. How do I allow multiple applications to use the same audio hardware without either (a) requiring (like JACK) that they all use the same sample rate and buffer size or (b) using the rather unreliable dmix ALSA library layer?
5. How do I provide a common volume control panel that allows to me control the relative gain of different applications all in one place ?
I could go on.
- melony 5y agoWhat about PipeWire?
- sho_hn 5y agoPipeWire is an intentional swamp draining effort that takes a lot of these ideas/solutions, and applies them more broadly. In the audio domain it does so by scaling to the requirements of competing APIs like JACK and implementing them as well. But it also expands them to the video domain (think arbitrating access to camera devices, or processing chains spanning multiple processes), which has a lot of the same challenges. And underneath it's built on Linux kernel infrastructure (e.g. dmabuf) that wasn't as present during the early PulseAudio days. A decent one sentence-summary for PipeWire is shell pipes for A/V between processes, with pluggable policy (hello mixer) and plugins to inject sources into the graph.
- BiteCode_dev 5y agoWhen Pulse audio came around, pipewire didn't exist. In fact, the infra required to build it didn't either.
- Spivak 5y agoLike I get that PulseAudio was unreliable for many years that fostered hate for it but it's absolutely crazy that people say that it's useless. You need something to collect sound streams from applications and mics, mix them, transform them, and output them to a bunch of different kinds of hardware with different requirements. Like Pipewire is fantastic but it's just a more reliable PA.
- BiteCode_dev 5y agoYes, it was a necessary endeavor, but the implementation never lived up to the task. I'm glad Pipewire is now getting traction, as I fear PulseAudio will never be able to be the stable and robust solution we need for audio on Linux. Particularly, it handles badly sleep modes, hot plugging sources, and BT, which in 2021 is not acceptable. I regularly have to set things up manually using pavucontrol. But yes, we needed it, and I thank the people that tried.
- handrous 5y ago> Like I get that PulseAudio was unreliable for many years that fostered hate Unreliable, and a shocking resource hog. Did that part ever get better, or did we just stop caring because memory sizes and core counts kept going op?
- jatone 5y agoneither, when pulseaudio was built there where problems all up and down the stack. from the kernel, alsa, and userspace. the effort around pulseaudio stabilized and resolved most of the problems in the kernel and alsa. leaving most of the problems in the implementation of pulseaudio. pipewire is now building off that giant amount of work pulseaudio effort resulted in and is able to reuse pulseaudio's IPC framework to seamlessly replace pulseaudio itself.
- heavyset_go 5y agoI stopped caring because PipeWire works well and ships as a drop-in replacement for PulseAudio and Jack by default.
- PaulDavisThe1st 5y agoIt's not quite a drop-in replacement for JACK yet, but I have very little doubt that it will get there.
- ahefner 5y agoAn answer to most of these might be to fix and extend ALSA rather than wallpapering over it and treating it like abandonware.
- PaulDavisThe1st 5y agoALSA was written to allow psuedo-devices to be implemented in user-space, which is how PulseAudio (and now Pipewire) does what it does. Nobody is abandoning ALSA, it continues to be both the device driver layer and the lowest layer of the audio stack in user-space. [ EDIT: you could make an argument that after many years of experience, it's time to put the lessons learned from JACK and PulseAudio into ALSA itself, and have ALSA provide the sorts of audio capabilities that the two of them, combined, enabled. I don't have much of a position on this compared with the Pipewire approach, which is to do the same thing, but outside of ALSA. There are good arguments for both, but Pipewire is what we have, and it remains as dependent on ALSA as JACK and PulseAudio and just about all other Linux audio has been since 2000 ]
- craftkiller 5y agowhich is funny because that's exactly how ALSA was started: https://lobste.rs/s/moflv5/freebsd_audio_from_perspective_happy#c_mqvroo https://lobste.rs/s/moflv5/freebsd_audio_from_perspective_ha...
- md8z 5y agoThat comment is somewhat problematic and I went into detail about it last week: https://news.ycombinator.com/item?id=28856907 https://news.ycombinator.com/item?id=28856907
- PaulDavisThe1st 5y agoGreat comment. Sorry that I missed this at the time.
- PaulDavisThe1st 5y agoI've been developing audio & MIDI software for Linux since about 1997. Maybe that makes me a special case, but none of the experience described by the post is familiar to me. I even used to use xmms with ALSA. There's some acorns of truth in that account, but it's been turned into a paragraph of hand-waving half-truth.