clap

CLAP Audio Plugin API
Log | Files | Refs | README | LICENSE

commit c56eaa9aee042031ebb31f073a416f13d5d12bb2
parent ed43574b1b026c3d9a4af0da6862b9dcea15b765
Author: Alexandre Bique <bique.alexandre@gmail.com>
Date:   Tue, 15 Aug 2023 11:13:13 +0200

specify the sample size to be used when activating the audio port

Fixes #321

Diffstat:
MChangeLog.md | 1+
Minclude/clap/ext/draft/audio-ports-activation.h | 8++++++--
2 files changed, 7 insertions(+), 2 deletions(-)

diff --git a/ChangeLog.md b/ChangeLog.md @@ -5,6 +5,7 @@ * [configurable-audio-ports.h](include/clap/ext/draft/configurable-audio-ports.h): simplify the design * [gui.h](include/clap/ext/gui.h): documentation clarifications * [entry.h](include/clap/entry.h): documentation clarifications +* [audio-ports-activation.h](include/clap/ext/draft/audio-ports-activation.h): specify the sample size to be used when activating the audio port. ## Draft extensions diff --git a/include/clap/ext/draft/audio-ports-activation.h b/include/clap/ext/draft/audio-ports-activation.h @@ -26,7 +26,7 @@ /// clap_host_audio_ports.rescan(CLAP_AUDIO_PORTS_RESCAN_LIST). static CLAP_CONSTEXPR const char CLAP_EXT_AUDIO_PORTS_ACTIVATION[] = - "clap.audio-ports-activation/draft-1"; + "clap.audio-ports-activation/draft-2"; #ifdef __cplusplus extern "C" { @@ -42,12 +42,16 @@ typedef struct clap_plugin_audio_ports_activation { // It is only possible to activate and de-activate on the audio-thread if // can_activate_while_processing() returns true. // + // sample_size indicate if the host will provide 32 bit audio buffers or 64 bits one. + // Possible values are: 32, 64 or 0 if unspecified. + // // returns false if failed, or invalid parameters // [active ? audio-thread : main-thread] bool(CLAP_ABI *set_active)(const clap_plugin_t *plugin, bool is_input, uint32_t port_index, - bool is_active); + bool is_active, + uint32_t sample_size); } clap_plugin_audio_ports_activation_t; #ifdef __cplusplus