Pipewire for pro audio

Optimize your system for ultimate performance.

Moderators: MattKingUSA, khz

thebutant
Established Member
Posts: 169
Joined: Sun Nov 18, 2012 12:59 pm
Has thanked: 50 times
Been thanked: 8 times

Pipewire for pro audio

Post by thebutant »

As Pipewire seems to become the new standard, I'd really like to be less confused about it.
So please join in and tell your experiences and how it works for you.

I'm not too interested in how Pipewire replaces Pulseaudio, as this seems to be going rather smoothly, and also Pulseaudio isn't an environment for audio related work anyway. Not the same way as Jack.
So what I need to understand is how to replace Jack with Pipewire in a sufficient way.

When trying to use Jack applications and the Jack workflow in Pipewire, I'm so far missing the power of Qjackctl or Cadence. The setup dashboards that these provide.
And when running Qjackctl on top of Pipewire, I'm missing the PulseAudio JACK Sink, which can route non-jack audio into Jack.

I'm quite excited about Pipewire, I like the idea of not running Jack on top of something else, but rather have everything running the same environment.
Yet, I don't manage to get my Jack workflow replaced by what Pipewire is currently providing.
What's the proper way?
Basslint
Established Member
Posts: 1516
Joined: Sun Jan 27, 2019 2:25 pm
Location: Italy
Has thanked: 385 times
Been thanked: 299 times

Re: Pipewire for pro audio

Post by Basslint »

I am not pro by any means and have not been doing a lot of music lately but I switched to Pipewire some months ago (from Pulseaudio + JACK) and I have zero regrets. It was as easy as installing Pipewire and a session manager (I recently switched from pipewire-media-session to Wireplumber which seems stable so far) and everything just works. There is at least one person I know who's doing more serious work on Pipewire and he has no issues. Give it a try :D
The community of believers was of one heart and mind, and no one claimed that any of his possessions was his own, but they had everything in common. [Acts 4:32]

Please donate time (even bug reports) or money to libre software 🎁

Jam on openSUSE + GeekosDAW!
User avatar
wjl
Established Member
Posts: 224
Joined: Fri Mar 17, 2017 12:27 pm
Location: near Frankfurt, Germany
Has thanked: 48 times
Been thanked: 26 times
Contact:

Re: Pipewire for pro audio

Post by wjl »

thebutant wrote: Tue Apr 19, 2022 9:12 am ... when running Qjackctl on top of Pipewire, I'm missing the PulseAudio JACK Sink, which can route non-jack audio into Jack.
Trying it on Arch, and I think there's helvum which is a Carla/Catia/QJackctl replace wannabe. Doesn't seem quite ready IMO, but it's a start...
more about me on my blog
User avatar
sysrqer
Established Member
Posts: 2523
Joined: Thu Nov 14, 2013 11:47 pm
Has thanked: 320 times
Been thanked: 151 times
Contact:

Re: Pipewire for pro audio

Post by sysrqer »

There is qpwgraph, which is sort of qjackctl for pipewire.

However, I've got pipewire running and if I open qjackctl I see all the things that would have gone into pulseaudio jack sink, they appear as individual clients so you can put firefox through carla for example.
thebutant
Established Member
Posts: 169
Joined: Sun Nov 18, 2012 12:59 pm
Has thanked: 50 times
Been thanked: 8 times

Re: Pipewire for pro audio

Post by thebutant »

Thanks so much for your tips!

How much of Jack is needed when running Pipewire?
For instance, when installing jackd2 (if I'm not wrong) you get the question of whether you wish to enable realtime processing.
Is this already done with Pipewire?

With a functional Pipewire system, how much of the additional usual audio packages should one install - jackd2, a2jmidid etc?
christobal
Established Member
Posts: 108
Joined: Sun Sep 01, 2019 12:58 pm
Has thanked: 21 times
Been thanked: 11 times

Re: Pipewire for pro audio

Post by christobal »

thebutant wrote: Tue Apr 19, 2022 2:52 pm Thanks so much for your tips!

How much of Jack is needed when running Pipewire?
For instance, when installing jackd2 (if I'm not wrong) you get the question of whether you wish to enable realtime processing.
Is this already done with Pipewire?

With a functional Pipewire system, how much of the additional usual audio packages should one install - jackd2, a2jmidid etc?
None of jack is needed when you have pipewire. The pipewire-jack package takes care of all jack stuff.

However the same old realtime config stuff for kernel/etc that has always been recommended is still recommended.


This is worth a read though for setting up a config file for some sane defaults: https://gitlab.freedesktop.org/pipewire ... onfig-JACK

Also, as for using qjackctl. I dont really see the need to be fair. If I'm launching Carla for example I prefer to do just launch if from terminal with: "PIPEWIRE_LATENCY=256/48000 Carla" (or whatever latency you want). You can run different programs with different buffersize at the same time if you want.

Also ardour lets you set buffersize directly in its audio settings. It works fine for me with pipewire.

pw-top is also a nice command that gives you an overview over current applications use of pipewire and their buffer/freq.
OS: Manjaro
Amp: Echolette M40 / NG51S Tape Echo
Strings: Martin D15M, Yamaha FG-180, Alhambra 5P, Yamaha Revstar
User avatar
bluzee
Established Member
Posts: 339
Joined: Mon Nov 30, 2020 11:43 pm
Has thanked: 18 times
Been thanked: 88 times

Re: Pipewire for pro audio

Post by bluzee »

I assume all must use the same sample rate though surely?
User avatar
sysrqer
Established Member
Posts: 2523
Joined: Thu Nov 14, 2013 11:47 pm
Has thanked: 320 times
Been thanked: 151 times
Contact:

Re: Pipewire for pro audio

Post by sysrqer »

bluzee wrote: Tue Apr 19, 2022 6:59 pm I assume all must use the same sample rate though surely?
Definitely not! That's one of pipewire's main advantages.
User avatar
bluzee
Established Member
Posts: 339
Joined: Mon Nov 30, 2020 11:43 pm
Has thanked: 18 times
Been thanked: 88 times

Re: Pipewire for pro audio

Post by bluzee »

How do they keep it from resampling then? There must be some way to lock it and hopefully some way to block pulseaudio applications from access while using Jack applications.
glowrak guy
Established Member
Posts: 2325
Joined: Sat Jun 21, 2014 8:37 pm
Been thanked: 256 times

Re: Pipewire for pro audio

Post by glowrak guy »

I found this page very helpful.

https://wiki.debian.org/PipeWire

Scrolling down a bit, is a section on pipewire bypassing jackd. I followed the several steps,
and was able to run my most often used audio software without jackd or qjackctl etc.

There was some trial and error using the qpwgraph pipewire connections gui, but a lot was just me being rusty.
What worked for me was
1. AVLinux with testing repositories activated (be careful not to do this on your only production setup!)
2. Installing all the pipewire sundries
3. Launching a system-D session
4. launch wireplumber
5. launch audio app(s)
6. launch qpwgraph, and get settled in, see what works etc.
7. Record the results with timemachine

In a non-system-D session, wireplumber failed due to some permissions issue regarding setting a value
of -11 for "nice".

I used rakarrack, guitarix, yoshimi, reaper with plugins, and timemachine, time to de-stress now.
Cheers
thebutant
Established Member
Posts: 169
Joined: Sun Nov 18, 2012 12:59 pm
Has thanked: 50 times
Been thanked: 8 times

Re: Pipewire for pro audio

Post by thebutant »

I'm trying to get things going on Pop!_OS 22.04 beta, as it's a clean distro running Pipewire by default.

However, I'm not able to get Jack into Pipewire. They both work, but seperately.

On a fresh install with no Jack, I installed yoshimi.
Yoshimi then installed Jack (jackd+jackd2 etc) as a dependency. And when opening Yoshimi, it starts Jack.
Well, that's not really so bad. Because I can then also launch Qtractor, Carla, Reaper and Mixbus 32C (these are the ones I've tried now).
But they all run through Jack. They don't show up in pw-top, and launching one of them demands starting up Jack. When doing so, my audio interface disappears from qpwgraph. It seem like Jack takes over.

So everything kind of works, but Jack applications don't show up in pw-top or qpwgraph (except for Qtractor, for some reason, but not in pw-top).
Instead I find them in Qjackctl or Carla, which then don't show any Pipewire audio.
So it works pretty much as my usual Pulseaudio + Jack setup, except that there's no bridge like pulseaudio-module-jack. Pipewire and Jack are just running seperately side by side.

When removing Jack, I'm not able to run any of my Jack software. I cannot make Pipewire fool them.

What can I do to prevent Jack from taking over?
Last edited by thebutant on Thu Apr 21, 2022 12:33 pm, edited 1 time in total.
User avatar
sysrqer
Established Member
Posts: 2523
Joined: Thu Nov 14, 2013 11:47 pm
Has thanked: 320 times
Been thanked: 151 times
Contact:

Re: Pipewire for pro audio

Post by sysrqer »

You don't need jack if you're running a reasonably up to date version of pipewire. If your pipewire is not up to date then I would recommend installing a current version.

You don't need jack at all and probably best to remove. If you can't get jack to work (as pipewire) then something isn't set up correctly.

I've just tried Yoshimi and it works with pipewire with default settings. In a pipewire environment you don't see 'pipewire' in the device preferences etc, you still see alsa, pulseaudio, jack and they are all just pipewire's 'emulation' of those (and can have different configurations for each).

I think you haven't updated the links to make jack applications refer to pipewire jack. Try this and see if that helps.
glowrak guy
Established Member
Posts: 2325
Joined: Sat Jun 21, 2014 8:37 pm
Been thanked: 256 times

Re: Pipewire for pro audio

Post by glowrak guy »

The following is from the wiki link in my post above, and I followed the steps:
-------------------------------------------------
"For JACK

JACK clients can be configured to output via PipeWire instead of JACK.

Install the pipewire-audio-client-libraries and libspa-0.2-jack packages, if not already installed.

Create this empty file:

# touch /etc/pipewire/media-session.d/with-jack

Either run JACK clients using the pw-jack wrapper, or copy:

# cp /usr/share/doc/pipewire/examples/ld.so.conf.d/pipewire-jack-*.conf /etc/ld.so.conf.d/

And run:

# ldconfig

This will replace the JACK server libraries with PipeWire's replacements at application runtime, by pointing the dynamic linker at the /usr/lib/x86_64-linux-gnu/pipewire-0.3/jack/ folder. "
--------------------------------------

Some screenshots of the qpwgraph connections gui app are at the bottom of this page:

https://www.kvraudio.com/forum/viewtopi ... start=1275
MusicMan74
Established Member
Posts: 15
Joined: Sat Nov 15, 2014 1:44 am
Has thanked: 1 time
Been thanked: 5 times

Re: Pipewire for pro audio

Post by MusicMan74 »

Maybe this 'Pro Audio Tuning Guide for Manjaro' (which includes a Pipewire section) would be of help?

https://github.com/ElizabethHarmon/ManjaroProAudio
thebutant
Established Member
Posts: 169
Joined: Sun Nov 18, 2012 12:59 pm
Has thanked: 50 times
Been thanked: 8 times

Re: Pipewire for pro audio

Post by thebutant »

I'm so happy for all these advices. Thank you so much!

And this is the moment I seem to always reach when I try to get the hold of Pipewire: The messy moment!
'Cause according to this guide you need the package pipewire-jack-audio-connection-kit, which I cannot find in any repos so far.

And according to the Manjaro guide, you should install pipewire-jack, which I also still have to find somewhere.

Yet according to glowrak guy, you can make it work without "pipewire-jack" or "pipewire-jack-audio-connection-kit", but rather just nudge Jack clients to the right direction.

To be honest, I'm guessing all the methods are right. And thanks for sharing them!
I'm not less confused, but I'll start out with glowrak guy's method. That way I don't have to add other repos or search around for packages.
Post Reply