Skip to content

Commit

Permalink
Adjust latency extension requirements
Browse files Browse the repository at this point in the history
- allow plugin_latency->get to be called during plugin->activate
- require host_latency->changed to be called during plugin->activate
  • Loading branch information
Trinitou authored and abique committed Sep 20, 2024
1 parent ebfe262 commit 3527890
Showing 1 changed file with 3 additions and 3 deletions.
6 changes: 3 additions & 3 deletions include/clap/ext/latency.h
Original file line number Diff line number Diff line change
Expand Up @@ -10,15 +10,15 @@ extern "C" {

typedef struct clap_plugin_latency {
// Returns the plugin latency in samples.
// [main-thread & active]
// [main-thread & (being-activated | active)]
uint32_t(CLAP_ABI *get)(const clap_plugin_t *plugin);
} clap_plugin_latency_t;

typedef struct clap_host_latency {
// Tell the host that the latency changed.
// The latency is only allowed to change if the plugin is deactivated.
// The latency is only allowed to change during plugin->activate.
// If the plugin is activated, call host->request_restart()
// [main-thread]
// [main-thread & being-activated]
void(CLAP_ABI *changed)(const clap_host_t *host);
} clap_host_latency_t;

Expand Down

0 comments on commit 3527890

Please sign in to comment.