List all plugin parameters?

I can see from the __plugin_modulation.lua example script here that I can set plugin parameters via a LUA script which is exactly what I need :slight_smile:

However I am wondering what is the best way to obtain the index and type of a specific parameter? I thought about listing all the parameters of a plugin via LUA but I could not wrap my head around the API and which functions/methods exactly I have to use for this.

Can someone help me figure this out?

Do you need to determine this information at run-time? If not, LV2 plugins a have a manifest file, which declare all parameters (ports in LV2 lingo). The lv2info tool from the lilv package can also list those for you in a nice formt.

Hey @SpotlightKid thanks for the hint regarding lv2info that looks promising. I don’t need the information at runtime, so that approach should work for me. I will give it a try.

Sharing my experience since I ran into a non-obvious issue:

The port numbers given by lv2info can not directly be mapped to the corresponding parameter index in a LUA script. The LV2 ports start with input and output configurations which I have to “deduct”:

For example to enable the LSP Artistic Delay Mono Plugin I am not using number 3 as the “Port” output indicates, but rather number 0. Maybe this is clear to everybody, but it took me a while to figure this out :smiley: so I thought it might be worth sharing