On Fri, Jan 29, 2016 at 6:29 PM, Neil C Smith <neilcsmith.net(a)googlemail.com
wrote:
On 29 Jan 2016 22:47, "theo"
<theo_linuxaudio(a)borm.org> wrote:.
- What is the point of this (re-)connection
behaviour of gstreamer? -
gstreamer doesn't suddenly become a "new
device" when it starts playing a
new song.
Well, in some ways it does, depending on how you're using GStreamer. I've
been having fun with this issue recently too.
This is all down to the default behaviour of the GStreamer JACK sink.
There are two properties that can be set on it that may be useful. The
first, connect, controls whether GStreamer auto-connects to the outputs - I
think using connect=0 will stop it auto-connecting. More recent versions of
GStreamer also allow you to set a port pattern for auto-connection, which
would allow you to control the behaviour you want without the patchbay.
Slightly more than this: almost all gstreamer-enabled applications consider
various user operations like "Stop" (and sometimes even "Pause" and
sometimes even "Next Song") to be a point at which they disconnect from
whatever audio backend gstreamer has been told to use. Specifically, they
"close" the "device".
The gstreamer backend was written to disconnect from JACK when told to
"close". This behaviour makes sense if the "device" was an actual
physical
device, but it doesn't make any sense in the context of a server like JACK.
I did try to patch the gstreamer JACK code to not do this, and remain
connected to JACK across time and space (so to speak) but it was harder
than I was willing to deal with.