Replies: 2 comments 7 replies
-
You maintain strings within your plugin class and use the state extension (https://github.com/free-audio/clap/blob/main/include/clap/ext/state.h) to store them in presets or in a project. |
Beta Was this translation helpful? Give feedback.
-
In most plugin APIs parameters are (numerical) values that can be changed by the host at runtime to affect the plugin's audio processing behavior. As such parameters need to have a clearly defined domain of possible values, and changing them needs to be realtime safe as it will be done from an audio thread. Arbitrary strings don't fit either requirement, and as such they're not suited for parameters in the model these plugin APIs follow. You could have an extension that exposes these arbitrary strings to the host, but there would need to be a clear use case for why the host would need to be able to modify them directly without the user interacting with a plugin-provided GUI (which, since it's provided by the plugin, can have much better knowledge of the plugin's domain). |
Beta Was this translation helpful? Give feedback.
-
This may be a noob question, but...
I'm dabbling with a CLAP-plugin testbed and have a question about, eg, string parameters. If my CLAP plugin accepts/requires a file name parameter (string), is there a way short of presets and GUI to set and get its value? This would be helpful in developing automated test rigs, etc. The API for ext/params.h seems constrained to float/int/numbers and is intertwined with automation.
Am I missing an API, extension or draft?
Thanks for any guidance!
Beta Was this translation helpful? Give feedback.
All reactions