Thread Rating:
  • 0 Vote(s) - 0 Average
  • 1
  • 2
  • 3
  • 4
  • 5
Can't switch to new audio output
I\'m using KDE with the phonon VLC backend, and when I connect to a bluetooth speaker, I can\'t get Sayonara to play through it. I have to restart the application. All the other applications I have can switch to the new output without issue.
Hello! Maybe the issue is similar to that one I experience. When playing a song and switching from my internal to my USB sound device, it\'s sufficient (but annoying) to restart the song. Can you try this out?

Our configurations are very different, you are using KDE (Neon, wasn\'t it?) and I am using Mint with Mate. I dropped KDE once because the sound handling was so different and problematic for me.
I hope, we can somehow bring our problems to the same denominator because I somehow want to avoid install a KDE and doing this annoying bluetooth configuration stuff. But if there\'s no other possibility, I would do of course.

Much blabla, my question is: Is it also sufficient for you to restart the song? Smile
Sorry I haven\'t responded for so long. I can\'t check this out on my current desktop that doesn\'t have bluetooth, but I\'ll check later on my laptop.
I just checked, and restarting the song does seem to work, at least when disable all other output sources.

Well, I also notice that when I renable the other sources it switches back to them and I can\'t push the output to bluetooth anymore. In KDE the audio widget allows one to drag and drop an \"application\"(e.g. Sayonara) to a \"device\" (e.g. bluetooth audio). This does NOT work with Sayonara. Even restarting the app doesn\'t help.

In KDE you can set audio preferneces so that e.g. for music it will prefer a certain device. Sayonara doesn\'t follow these preferences. All my other apps, such as spotify, vlc, etc., do.

[Edited on 10-5-2017 by johnny_boy]

[Edited on 10-5-2017 by johnny_boy]
There\'s probably a dbus interface i am currently not aware of and which is not implemented yet. I have to start some research. But give me some tine because the next month because i am not at home.

Open source also lives from its community. In this time you may do some research home, too what KDE expects from an application to be capable of this ability. If you want of course
I would love to help but I have absolutely no development experience. (Actually I once made a program in C++ that output the sum of two numbers.) Anyway, I thought source switching and assigning outputs to sources is handled by pulseaudio on most (all?) major distros. As far as I know, the plasma widget is only making use of features of pulseaudio, and one can do the same using something like pavucontrol.
The output of the sound stream is currently directed into pulseaudio.
When running pavucontrol, I can switch the output devices and the sound immediatly appears on that new sound interface. (see screenshot)
But when I activate the new sound source over the standard Mate sound configuration dialog, I have to restart the song or waiting for the next one.

Sayonara player chooses pulseaudio as output source when playing a song, and that\'s all. I really have no clue atm, where the problem is. Mate, pulseaudio, gstreamer or if I missed to implement a specific OS-Interface. I have to investigate that.

Attached Files Thumbnail(s)
Oh, that is very weird. It can\'t be a specific DE-interface as I doubt apps like spotify have done something special to handle all DE-specific needs. By the way, I\'m using Phonon VLC as the backend, not gstreamer. (The package on Ubuntu/KDE Neon is phonon-vlc-backend.)

Best of luck!
Sayonara always uses gstreamer. But the gstreamer sink was set to autoaudiosink. That means, sound is redirected to the sound system of your desktop environment. It is just a stream of bytes flowing to your desktop environment's sound server. This is pulseaudio on most systems per default. Pulseaudio is just a wrapper itself. It does sound composition (so you can play from multiple sources at the same time), resampling (afaik, pulseaudio resamples everything to 44100 Hz) and maybe apply equalizer settings (when you have installed a pulseaudio equalizer) and so on. After doing all this processing, pulseaudio redirects the sound to alsa or oss.

Gstreamer is basically a sound api, where you can do operations on sound buffers. There are alternatives for gstreamer like xine, mplayer, vlc. Phonon was special because it was a proxy before gstreamer, xine, vlc and direct show. So an application using Phonon VLC talks with the Phonon framework where sound is redirected to libvlc where it is redirected to pulseaudio and finally to alsa which redirects it to the sound card. The very first Sayonara version was using Phonon but a Qt developer warned me and told me Qt Phonon is dead and I should switch to Qt Multimedia or gstreamer. Finally, phonon support in Qt was dropped with Qt 5.

But now, Sayonara uses gstreamer directly. It creates a so called pipeline itself instead of trusting the playbin pipeline which was dynamic enough to fulfill all of the people's wishes Wink
The playbin pipeline used by a lot of programs is a black box where you don't have to think about anything, it's just working. A lot of applications (maybe spotify, too) uses this pipeline and they are working without issues. At the end of such a pipeline there's a sink where the sound "drops out" into your sound system.

Here is a list of gstreamer plugins. Just search for "sink" and you can see which sinks are available.

If you think one of those sinks can do what you miss, tell me and I can integrate it for you. But those sinks don't take a lot of parameters so I have only little influence to them. So I highly doubt that Sayonara is the only application not switching the output automatically because this is the task of your pulseaudio server.

In the current version, you can switch between automatic, pulseaudio and alsa sink. I am planning that you can select your device when using alsa but I have to implement some Alsa API functions. But I have to learn how to use this API first.

Forum Jump:

Users browsing this thread: 1 Guest(s)