ajboni / calvo

🧑🏼‍🦲 A jalv based lv2 plugin rack for your terminal.
https://ajboni.github.io/calvo/
GNU Affero General Public License v3.0
11 stars 2 forks source link

Integration with carla[-control] ? #32

Open falkTX opened 4 years ago

falkTX commented 4 years ago

Hello there. First of all, fantastic project! I always wanted to have something like this!

I am interested to know what is your reason to go with jalv as your host.

But regardless of it, how open are you for alternative backends? Because this project has my full interest to add a carla control mode.

Starting with v2.2 of Carla, there is a "carla-osc-gui" startup tool that creates a carla instance on the background and connects to it over OSC. The background carla keeps running, allowing us to connect to it later at any point (closing the gui does not stop the carla/sound) This seems the perfect mode for a CLI tool. So that one can remotely log into a machine, run it and see+control all the plugin stuff running there. With the bonus of being able to have the full GUI if connecting to this machine over OSC with carla-control. Just an idea.

Thanks for your attention

ajboni commented 4 years ago

Hello @falkTX thank you! The reason to go with jalv was because I run into a little trouble with mod-host (I can't really remember what) and decided to try jalv, It worked so well that I just kept it. The plan is(or was) to eventually add it as an alternative host.,

But regardless of it, how open are you for alternative backends? Because this project has my full interest to add a carla control mode.

I'm really open to add more backends (especially carla) adding it should be quite simple. Also I could really benefit from having a separate monitoring stream, bypass, and save rack status!

The app is designed to spawn multiples instances of the host, maybe that's the biggest change. Do you have any docs for the carla-osc-gui mode?

This seems the perfect mode for a CLI tool. So that one can remotely log into a machine, run it and see+control all the plugin stuff running there. With the bonus of being able to have the full GUI if connecting to this machine over OSC with carla-control. Just an idea.

Nice! Here's another idea, if calvo can connect to localhost via OSC I suppose it will be able to connect to a remote machine as well!

falkTX commented 4 years ago

Do you have any docs for the carla-osc-gui mode?

I dont have any docs for that, sorry, or for most of carla anyway.

There is developer documentation though. https://kx.studio/ns/dev-docs/CarlaBackend/group__CarlaHostAPI.html https://kx.studio/ns/dev-docs/CarlaBackend/group__CarlaUtilsAPI.html

The same API is used as C library, with a ctypes python file matching it. There are implementations of it with pipes and OSC, but meant for internal use. To be honest, I don't know what is the best option here for interoperability with node/js.

Here's another idea, if calvo can connect to localhost via OSC I suppose it will be able to connect to a remote machine as well!

That was my initial idea actually. usually on a modular host, there is no need to run multiple instances of the host, right?

So like, as the idea/thinking goes... we could run the host on the background on a machine, to which we can connect with carla-control or use CLI tools like calvo.

ajboni commented 4 years ago

The same API is used as C library, with a ctypes python file matching it. There are implementations of it with pipes and OSC, but meant for internal use. To be honest, I don't know what is the best option here for interoperability with node/js.

If there is a python binding I can definitely call via node, I'm already doing it with JACK and lilv. https://github.com/ajboni/calvo-cli-tools. I just need to make it a CLI command for the desired functions which It could be helpful for other projects as well. On the other hand, can't we directly do all operations via OSC ? There are some node libraries available (haven't used any). It would simplify a lot on my end and we will be technicaly able to support anything that carla-control does, (except for graphics of course)

That was my initial idea actually. usually on a modular host, there is no need to run multiple instances of the host, right?

That's right, and even better, I won't need to do the plugin inter-connections myself, but carla needs to be running in continuous rack mode I suppose.

So like, as the idea/thinking goes... we could run the host on the background on a machine, to which we can connect with carla-control or use CLI tools like calvo.

Yes, seems like a good idea. I have Carla 2.1.1 (git) , Whenever 2.2 comes out I can gladly make some tests.

falkTX commented 4 years ago

If there is a python binding I can definitely call via node, I'm already doing it with JACK and lilv.

There is yes, but...

I just need to make it a CLI command for the desired functions which It could be helpful for other projects as well.

I advise against this if using the python library. it does not scale if every single change needs to open a new process. And using the shared library (via python) as an "imports" of sorts in node is also a bit problematic, due to the audio and control being in the same process. (I can go into details if really needed, but it is just that node is a very complex project, there are things it can do that can block the audio side of things)

On the other hand, can't we directly do all operations via OSC ?

You can yes! There are only a few minor exceptions:

  1. starting custom (remote) guis is not supported at the moment (the amount of plugins that support this is limited, not worth the effort IMO)
  2. canvas "inline-display" not possible over OSC, the data through-put is simply too much to send over the network. (for example of inline-display see https://nextcloud.falktx.com/s/CLSsyqGR27TcTq2)
  3. vst "parameter text" also not supported, I did not bother too much with it since it would be problematic to implement properly.
  4. list of available (remote) plugins is not passed over OSC yet (but there are ways to find the local plugins)
  5. no file open/save over OSC yet

no. 4 and 5 are limitations due to me not finding a proper solution for the "remote filesystem" problem. as carla-control can be connected to a remote machine, a save/load operation will happen on that machine. so I need to support showing the remote filesystem.

ajboni commented 4 years ago
  • starting custom (remote) guis is not supported at the moment (the amount of plugins that support this is limited, not worth the effort IMO)

  • canvas "inline-display" not possible over OSC, the data through-put is simply too much to send over the network. (for example of inline-display see https://nextcloud.falktx.com/s/CLSsyqGR27TcTq2)

  • vst "parameter text" also not supported, I did not bother too much with it since it would be problematic to implement properly.

No problem. calvo won't suppory gui's of any kind.

list of available (remote) plugins is not passed over OSC yet (but there are ways to find the local plugins)

This seems like a stopper. I need the plugin database for the plugin browser. Maybe carla-no-gui should make the db on the system it is installed and expose it via the API. As last resort a companion app could be made to handle remote requests. Maybe a REST API or similar