I run pipewire and let me offer some generic tips:

* Make loopback devices that are always there for headphones/mic -- software doesn't handle connection/disconnection well

* Keep all your processing in carla (i load it with systemd as a user unit on login)

* You still need some way to control "pulse audio" (even though it's pipewire provided) for per-app volume control, profile selections, etc, so you probably want pavucontrol for that.

Thanks for the tips here. Could you elaborate on Carla? I tried Googling around but didn't mind much detailed information. I work on Lyrebird so could be helpful as you say.

Sure.

Carla: https://github.com/falkTX/Carla

It lets me install any normal audio pro audio plugins, for example https://github.com/xiph/rnnoise

It also does some cable management, but qpwgraph is maybe better for that.

I looked at your code and the approach (IMO) is kind of bad.

If you want to solve the problem of "voice changer", you can skip the UI entirely and just use plugin parameters. You can also skip the problem of managing the connections. And when you publish your work, every pro audio software (Ableton, Reaper, whatever) can use your audio processing.

Hope that helps.