Open Houston4444 opened 4 years ago
I like this idea, FWIW.
carla-control needs to know the OSC URL and ports of the main instance in order for this to work. so the remote executable would need to allow CLI parameters (contrary to main NSM) in order to pass these.
For guitarix, just start the remote UI, as long it is in the same LAN, it will connect via AVAHI handshake.
what if there are 2 instances of guitarix running, how does it know which one to connect to?
If there are two instances, the GUI process will pop up a window to let you select which engine you would control. And, you could use multiple GUI's to control one engine, but you can't control multiple engines with one GUI.
@falkTX arguments are not a problem here. There are already a lot of messages in raysession<->ray-daemon accepting indefinite number of arguments in the case they all are strings.
@brummer10 TBH, I'll prefer that a remote connect directly to the good instance if there are many running. Simpler and less confuse for user.
maybe we could also let the client send all the arguments he wants, with auto-replace of patterns such as $OSC_URL, $OSC_PORT, $HOSTNAME or whatever.
Currently I cant say much to this, as we didn't have a OSC interface implemented. We use rpc via (web)sockets to communicate between GUI and engine. So, I don't know what I need to make the initial connection via a osc call. For sure, we need command-line args pass to the GUI instance.
I think to add ':remote-gui:' capability to the server capabilities.
NSM can hide/show GUIs client if client has :optional-gui: capability, but it is not enough I think. In this existent case both GUI and engine of the client run on the same machine, and in almost case, show/hide GUI in NSM server only show/hide the main window (and doesn't stop GUI process).
The main goal of this new feature is to have a remote GUI for an NSM client running on another machine.
The idea is that client should have :remote-gui: capability. In this case, after NSM server registration, client will send to server an executable as argument to OSC path /nsm/client/remote_gui_executable (for example). Then, a new "remote" button will be available on RaySession window (or other NSM server GUI) similar to the 'GUI' client button. When user click on it, RaySession's GUI will start a process with the given executable and the client OSC port as argument.
Example with carla (supposing a carla_engine NSM compatible executable exists).
add NSM client carla_engine (executable) carla_engine -> NSM server : announce with ':remote-gui:' capability
carla_engine -> NSM server :
/nsm/client/remote_gui_executable carla_control
NSM Server -> NSM GUI :+1:/nsm/gui/client/remote_gui carla_control $client_url
Now in NSM server GUI, client can click on the client remote icon. Then NSM server GUI launch process:
carla_control $client_url
The remote should be closed with SIGTERM (by server GUI) when the client engine is stopped (from user or for another reason).
How does it sound ?