Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Parameter value output events after loading a state #446

Open
mwilliamson-fourier opened this issue Jan 24, 2025 · 1 comment
Open

Parameter value output events after loading a state #446

mwilliamson-fourier opened this issue Jan 24, 2025 · 1 comment

Comments

@mwilliamson-fourier
Copy link

Hello!

From some testing of CLAP plugins, it seems like there are (at least) two cases when the process() call will emit parameter value output events:

  1. When the user changes a parameter value, for instance by turning a dial in the UI
  2. When a state is loaded using load on clap_plugin_state

It's useful in the plugin host to be able to disambiguate these two cases, for instance to determine whether or not the plugin host needs to persist a new state (typically yes in case (1), no in case (2) since the plugin host has just provided said state).

What's the expected way of doing so using CLAP? I thought perhaps that plugins should set the CLAP_EVENT_DONT_RECORD flag on any output events resulting from a state load, but it doesn't seem like CLAP plugins tend to do this.

Alternatively, I thought perhaps there might be a pair of events that indicate the start and end of a sequence of events resulting from a state load, but I didn't see any to that effect.

Any guidance on the expected behaviour of plugins according to the spec would be much appreciated.

Thanks!

@baconpaul
Copy link
Collaborator

There is a pair of events from a gesture wrapping case 1. Maybe that could be a guide?

the problem with that is: badly written plugins may skip them and then your host will look buggy, I guess

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants