Page 1 of 1

Cadence: issues with system audio

Posted: Fri Jun 22, 2018 10:07 am
by SundavarBlaka
I have an issue with Cadence and the audio coming from the system and from applications (e.g. from VLC or youtube).

If I plug my guitar in my audio interface (Fousrite Scarlett solo) connected via USB and then start Cadence I can hear the sound coming form it in my headphones (effects applied with guitarix work), but app's and system's audio is still coming out from PC speakers.
I found that if I stop and restart PulseAudio from Cadence everithing seems to work fine, I can hear both guitar and apps in my headphones. But now if I stop JACK via Cadence system audio stops working. The only solution I found is runnig this script after stopping Cadence:

Code: Select all

killall pulseaudio

rm -r ~/.config/pulse/* 
rm -r ~/.pulse*
sleep 10s
 
pulseaudio  -k
I'm currently running Ubuntu 16.04 with KDE desktop with the latest kernel update available. I've added KxStudio repos following the instructions found on the official website and installed the following pakages:
  • kxstudio-default-settings
  • kxstudio-repos
  • kxstudio-repos-gcc5
  • kxstudio-meta-audio-plugins
To simulate amps and effects I use Guitarix, to play audio VLC or audacity

These are actually my settings:
cadence.jpg
cadence.jpg (69.59 KiB) Viewed 1790 times
settings.jpg
settings.jpg (66.91 KiB) Viewed 1790 times
settings1.jpg
settings1.jpg (46.68 KiB) Viewed 1790 times
Is there any way to have my system audio work without running the script and without having to stop/restart pulseaudio?

(I'm sorry for any mistake made, since English is not my native language)

Re: Cadence: issues with system audio

Posted: Sun Jun 24, 2018 10:26 am
by SundavarBlaka
I tried, but it does not work for me. If I use the autostart option I can't hear app's sound form headphones and I have to stop and restart it manually. However, regardless of the way this bridge is started, if I stop it or I stop jack system audio is missing and I have to run that script to restore it.
The problem is not primarily how to hear system audio from my audio interface, but how to pass smoothly from jack (using a bridge or not) to pulse and the other way around, without having to run that script to restore audio at the end of the process...

Maybe I have misinterpreted what jack is or there is another way to do these things...

Re: Cadence: issues with system audio

Posted: Tue Aug 21, 2018 9:53 pm
by vitaminx
I would simply get rid of Pulseaudio as it's not very good for making music, it adds latency.
The build-in ALSA and Jack is all you need.

I'm using Cadence with "ALSA -> Loop -> JACK bridge" and it works allright.

Re: Cadence: issues with system audio

Posted: Wed Aug 22, 2018 11:31 am
by vitaminx
falkTX wrote:Except if you need skype, or firefox, or spotify
Spotify does not need pulseaudio!

For Firefox and Skype there's a simple trick:

Code: Select all

sudo apt-get install apulse
apulse firefox
Voilá, you get sound without pulseaudio.
falkTX wrote:a bunch of other applications out there that don't speak alsa anymore and just pulseaudio.
What applications are you referring to?
I didn't encounter anything else than Firefox and Skype that needs Pulseaudio...

Re: Cadence: issues with system audio

Posted: Wed Aug 22, 2018 12:29 pm
by CrocoDuck
falkTX wrote:Hopefully pipewire will not be a big mess like pulseaudio was at the beginning.
Oh I did not know about that project. Looks interesting...

Re: Cadence: issues with system audio

Posted: Wed Aug 22, 2018 2:40 pm
by vitaminx
falkTX wrote:last time I tried with raw alsa, I got no sound at all.
Then you had a different problem. The official Spotify Linux client definitely works with alsa out of the box.
Maybe you had an issue similar to that: https://bbs.archlinux.org/viewtopic.php?id=203951
falkTX wrote:apulse seems really the wrong solution.
Ya I guess it's more a workaround than a solution.
Still it's less pain to use apulse (or Chrome instead of Firefox for that matter) than to try serious audio production with Pulseaudio in the tool chain.
falkTX wrote:Hopefully pipewire will not be a big mess like pulseaudio was at the beginning.
I've never heard of it, what's pipewire about?

Re: Cadence: issues with system audio

Posted: Wed Aug 22, 2018 3:18 pm
by finotti
vitaminx wrote:
falkTX wrote:Hopefully pipewire will not be a big mess like pulseaudio was at the beginning.
I've never heard of it, what's pipewire about?
https://pipewire.org/

Re: Cadence: issues with system audio

Posted: Wed Aug 22, 2018 3:47 pm
by vitaminx
finotti wrote:https://pipewire.org/
First thing that came to my mind:
Image

I never really understood in first place why anyone would prefer Pulseaudio, at least it adds no value to anything I would use, especially for musicians.
Ok it does have Bluetooth audio - but then again the pulseaudio implementation is not very good and you get choppy sound.

I didn't read the technical details of pipewire, but here is my uninformed opinion, that nobody asked for :D

> Capture and playback of audio and video with minimal latency.
Got that already with Jack and ALSA, "minimal" is quite vague TBO.

> Real-time Multimedia processing on audio and video.
We got that for audio already. Would be nice to see what they have planned for video though.

> Multiprocess architecture to let applications share multimedia content.
I don't know what to make of this statement.
Sounds like marketing :P But maybe it's just me not getting it.

> GStreamer plugins for easy use and integration in current applications.
GStreamer is not something I use, but maybe it's popular, I don't know.

> Sandboxed applications support. See Flatpak for more info.
Oh god, now I know why my subconscious mind was sceptical about this project, it's related to Lennart Poettering.
No thanks.

Re: Cadence: issues with system audio

Posted: Mon Sep 17, 2018 7:46 pm
by korakios
I am sure the OP found a solution ,but every time I hear removing pulse system on 2018 makes me :evil:

First install pavucontrol
(Off-topic ,if anyone is using a dedicated audio card for jack , simply open pavucontroland and on configuration tab, set that dedicated card to off. That should prevent ,any messing launching jack (although I never had any problems) )
On-topic, simply select jack-sink as output device (on pavucontrol-'playback' tab) to hear the sound from jack's audio and not the preffered card from pulseaudio.

Pulseaudio Rocks and make things easy on everyday desktop experience 8)
If it's causing xruns (indeed it consumes some DSP ) simply disable autospawn and stop pulseaudio bridge....

Re: Cadence: issues with system audio

Posted: Tue Sep 18, 2018 12:49 am
by vitaminx
korakios wrote:I am sure the OP found a solution
OP, I really hope you found a solution that works best for you.
korakios wrote:Pulseaudio Rocks and make things easy on everyday desktop experience 8)
And you are probably right as long as we talk about "everyday desktop experience".

Let me explain my reasoning a little with a post from Lennart Poettering himself back from 2010, talking about his goal and the mission of Pulseaudio: http://0pointer.de/blog/projects/when-p ... n-not.html

He categorizes the audio systems like this:
Consumer Audio = PulseAudio (dynamic latency, power management, shared ressources, inexperienced users)
Pro Audio = Jack (minimal fixed latency, dedicated system resources for audio, professional users)

Your choice between jack and/or pulseaudio may depend on how serious or Pro (Lennarts words) you are as a musician with Linux, and if you are willing to learn enough about Linux to be comfortable without a consumer grade audio system.

And if you check his slides you may understand why I am reluctant to adopt software developed by him in particular, he says literally that nobody's making any money with Linux audio. And that he himself is not a musician.
I understand from this that he assumes that we are all Linux audio amateurs and need consumer audio only, which would then be covered by his Pulseaudio.