News for hackers. Stuff that matters.
Re:Bye CUPS: Printing with Netcat by int_19h on Tuesday August 03, 2021 @08:41PM (#28055985)
I remember back when ALSA was a hot new thing on Linux, and it kinda sorta solved the "only one app can play things at the same time" problem that existed with the traditional OSS.

Meanwhile, OSS on FreeBSD just worked.

Re:Bye CUPS: Printing with Netcat by rescbr on Tuesday August 03, 2021 @08:49PM (#28056032)
Rinse & repeat when every desktop environment brought their own audio daemons, then later PulseAudio and now PipeWire.

I still roll my eyes and I don’t get surprised every couple of years when somebody releases a yet another Linux audio daemon.

Maybe it’s some kind of Linux tradition.

At least PipeWire is saner compared to PulseAudio.

Re:Bye CUPS: Printing with Netcat by PaulDavisThe1st on Tuesday August 03, 2021 @10:39PM (#28056606)
> every couple of years when somebody releases a yet another Linux audio daemon.

You seem to be stuck in, oh, maybe 2008.

There hasn't been "yet another Linux audio daemon" in more than a decade. JACK came along in the early 2000's (I wrote it), and PulseAudio in 2004 or thereabouts. All that nonsense with esd, artsd etc. was over because the aughts were over.

Re:Bye CUPS: Printing with Netcat by WhyNotHugo on Wednesday August 04, 2021 @11:11AM (#28061918)
You seem to have missed pipewire.

While it supports the same APIs as Pulseaudio, it's still a new audio (and video) daemon.

Re:Bye CUPS: Printing with Netcat by PaulDavisThe1st on Wednesday August 04, 2021 @03:22PM (#28065087)
The GP is about pipewire, and was complaining that it's "just another linux audio daemon". I concluded that it wasn't necessary to mention it in the context of my comment.
Re:Bye CUPS: Printing with Netcat by scns on Wednesday August 04, 2021 @04:14AM (#28058535)
Thank You For JACK.

Even though i don't do audio on Linux.

Re:Bye CUPS: Printing with Netcat by calvinmorrison on Tuesday August 03, 2021 @11:34PM (#28056930)
artsd.... now that's a name I haven't heard in a long time!
Re:Bye CUPS: Printing with Netcat by woofie11 on Wednesday August 04, 2021 @07:16AM (#28059658)
My problem is that all of these are incompatible. Woe be to whomever has an OSS app, an ALSA app, a JACK app, and a PulseAudio app, all of which want to run at the same time.

I don't get why this was never fixed at the kernel level. You have onions of layers.

Re:Bye CUPS: Printing with Netcat by bitwize on Wednesday August 04, 2021 @07:29AM (#28059736)
PipeWire solves this problem. It provides ALSA, JACK, and PulseAudio emulation (no one has actually used OSS on Linux in decades).

It is the audio solution for Linux.

PipeWire does video too, and when combined with a compatible Wayland compositor, serves as a replacement for remote X11.

Re:Bye CUPS: Printing with Netcat by coldpie on Wednesday August 04, 2021 @10:51AM (#28061675)
Replace "PipeWire" with "PulseAudio" and hey look it's 2010 all over again.

Don't worry, THIS time we got right FOR SURE.

Re:Bye CUPS: Printing with Netcat by majewsky on Thursday August 05, 2021 @05:58AM (#28071669)
PulseAudio never intended to replace Jack. And in fact, that's one of its biggest failings.

FWIW, I have recently switched from PulseAudio to PipeWire. I remembered how rough the switch from plain ALSA to PulseAudio was, and thus was utterly baffled how smooth the transition to PipeWire is. I just uninstalled PulseAudio, installed PipeWire, rebooted, and everything just worked, down to the Bluetooth headset that I never quite got to work well with PulseAudio.

Re:Bye CUPS: Printing with Netcat by woofie11 on Thursday August 05, 2021 @12:37PM (#28076081)
.... Wait a minute. You got a bluetooth headset working reliably with Linux? Tell me more...
Re:Bye CUPS: Printing with Netcat by rescbr on Thursday August 05, 2021 @12:50PM (#28076278)
Yeah, I had the same experience. With PipeWire it (mostly) just works, and reliably. The only thing I'm missing is always presenting the microphone as an usable device and only switching codecs/profile when the microphone is being used.
Re:Bye CUPS: Printing with Netcat by ta988 on Tuesday August 03, 2021 @10:14PM (#28056479)
Since I switched to pipewire, my audio is crackling every time the cpu is loaded (a ryzen 7...) not even jack was struggling with that on this machine
Re:Bye CUPS: Printing with Netcat by m45t3r on Tuesday August 03, 2021 @11:55PM (#28057084)
Double check that you're running PipeWire with rtkit (this is the default with PulseAudio, AFAIK it is not the default yet on PipeWire).

It is really important to run a sound daemon with realtime privileges. This is the only way to ensure no cracks.

Re:Bye CUPS: Printing with Netcat by ta988 on Wednesday August 04, 2021 @08:50PM (#28068400)
Thanks I'll check that
Re:Bye CUPS: Printing with Netcat by PaulDavisThe1st on Tuesday August 03, 2021 @10:45PM (#28056634)
Pipewire is not finished at this point. It is being deployed "early" by some distros, apparently in the belief that it will help find bugs and help them being fixed.
Re:Bye CUPS: Printing with Netcat by feanaro on Tuesday August 03, 2021 @10:11PM (#28056464)
> At least PipeWire is saner compared to PulseAudio.

In what way?

Re:Bye CUPS: Printing with Netcat by PaulDavisThe1st on Tuesday August 03, 2021 @10:40PM (#28056610)
Pipewire implements both ALSA psuedo-devices, the JACK API and the PulseAudio API. You only need a single daemon to address all possible audio I/O needs, something that PulseAudio could not do.
Re:Bye CUPS: Printing with Netcat by jandrese on Tuesday August 03, 2021 @11:09PM (#28056771)
That doesn't sound like a recipe for sanity.
Re:Bye CUPS: Printing with Netcat by yobert on Tuesday August 03, 2021 @11:17PM (#28056821)
My experience with pipewire is it works better than pulseaudio, is faster, has lower latency, and fewer bugs. And it gets better all the time!
Re:Bye CUPS: Printing with Netcat by codedokode on Wednesday August 04, 2021 @08:39AM (#28060293)
What I don't like is that audio systems on Linux are too complicated. For example, all that ALSA needs to do is to provide exclusive access to a device (only one program at a time) and send samples into it unmodified (no bit depth change, no resampling, no mixing, no volume adjustment etc). But open source developers cannot do such a simple thing. They added thousands of unnesessary features, hundreds config options and turned ALSA into a monster. When it should be just a dumb backend for PulseAudio.
Re:Bye CUPS: Printing with Netcat by kelnos on Wednesday August 04, 2021 @01:31AM (#28057562)
It didn't, though, initially. On hardware that supported multiple streams, it worked (assuming the driver for that hardware knew how to do it), but for hardware that didn't, you had to use the ALSA dmix plugin, which for the longest time wasn't enabled by default because it was the cause of some audio artifacts.
Re:Bye CUPS: Printing with Netcat by int_19h on Wednesday August 04, 2021 @04:52AM (#28058753)
dmix is what I meant. But you had to use ALSA to use dmix, so in practice, it was the biggest reason to switch for most.
Re:Bye CUPS: Printing with Netcat by coryrc on Tuesday August 03, 2021 @10:32PM (#28056563)
OSS got that ability decades ago, yet we still have ALSA and then the others :(
Re:Bye CUPS: Printing with Netcat by PaulDavisThe1st on Tuesday August 03, 2021 @10:44PM (#28056629)
OSS did not have the ability when it was removed from the kernel and replaced by ALSA, which did have that ability already.

There were (and are) many problems with the OSS API, a number of which continue to exist in the ALSA API too.

All serious audio APIs (plugins, or native audio I/O) use a pull model at the bottom of the stack, so that i/o is driven by the hardware. You can layer a push model (where software does blocking read/write calls whenever it wants) on top of that, but not the other way around.

And yes, OSS and ALSA both implement select/poll etc. for audio devices, but do not enforce the use of this model, resulting in the 2000s being filled with Linux (and *BSD) apps that couldn't function correctly without oodles of buffering.

Re:Bye CUPS: Printing with Netcat by gjasny on Wednesday August 04, 2021 @04:30AM (#28058631)
I remember the mixer interface (channel volumes, mute states, routing matrix) was far superior with ALSA.

I used a script to toggle the SPDIF output stream of my Soundblaster Live to get track marks on the Mini Disc player recording the output.