Ticket #170 (new enhancement)
Opened 2 years ago
support for JACK clients with dynamic ports
|Reported by:||http://wayne.in-giro.org/||Owned by:||-|
|Keywords:||Audacity,VLC,dynamic port||Cc:||wayne@…, nedko@…|
Audacity, and other JACK client apps (e.g. VLC), create their JACK ports on demand (i.e. at the moment of playing and recording). what is more, these ports are often 1) dynamically named (e.g. with a counter); 2) disappear at the end of the record/playback operation.
with this scenario, they are basically unable to connect to JACK in LADISH, since they only create JACK ports once it starts playing/recording. thus, Audacity, for example, will always fail trying to connect to JACK, and there is nothing in Gladish with which i can wire Audacity to output ports since it is not present in the JACK graph (because it is not playing recording). it can be wired after playback/recording has started, but the connection is not restored since with Audacity the port name changes every time.
the situation in a Room is the same. Audacity does allow one to choose the JACK device to connect to for playback and recording. however, only raw JACK ports (like system, jmcore, etc) are listed and available (which would bypass the whole Room/Studio). perhaps it is an issue with Port Audio, which Audacity uses on Linux at least.
the basic issue seems to be with any Audacity-like app that creates their JACK ports on demand, i.e. when a request to play or record comes in. worse yet, the ports are removed upon stopping playback or recording.
VLC is like this also. however, at least VLC allows one to set a regular expression of which ports to connect to, so it will reconnect on each playback to the Room virtual output ports if something like "audio_playback*" is used. unfortunately, Audacity only allows one to select from available JACK ports, which as i said are all raw JACK ports.
it seems like it could be a problem for LADISH in its current implementation if these apps do not allow one to edit the JACK ports to connect to (like Audacity).
one solution could be to use regular expressions to specify connections between clients in LADISH, similar to that done by VLC. thus, one could simply state that Audacity ports named "in*" should be connected to the virtual input ports, and "out*" to the virtual output ports in a room. of course, it is more difficult than that, as how do we say which port goes to which, when there are more than 1 port choices (e.g. in a stereo situation).