clap

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

commit cf78219971cd12b2d06db17dc071f263413de3f7
parent 0fcd0a2a95562a232c4997cff9f4535ccba5d0c2
Author: Alexandre BIQUE <bique.alexandre@gmail.com>
Date:   Thu, 29 Apr 2021 10:13:07 +0200

Program Changes is gone, the plugins can do it via MIDI events

Diffstat:
Minclude/clap/events.h | 22++--------------------
Dinclude/clap/ext/draft/program.h | 44--------------------------------------------
2 files changed, 2 insertions(+), 64 deletions(-)

diff --git a/include/clap/events.h b/include/clap/events.h @@ -14,11 +14,8 @@ typedef enum clap_event_type { CLAP_EVENT_PARAM_SET, // param attribute CLAP_EVENT_TIME_INFO, // time_info attribute CLAP_EVENT_CHORD, // chord attribute - - /* MIDI Style */ - CLAP_EVENT_PROGRAM, // program attribute - CLAP_EVENT_MIDI, // midi attribute - CLAP_EVENT_MIDI_SYSEX, // midi attribute + CLAP_EVENT_MIDI, // midi attribute + CLAP_EVENT_MIDI_SYSEX, // midi attribute } clap_event_type; /** Note On/Off event. */ @@ -107,20 +104,6 @@ typedef struct clap_event_midi_sysex { uint32_t size; } clap_event_midi_sysex; -/** - * Asks the plugin to load a program. - * This is analogue to the midi program change. - * - * The main advantage of setting a program instead of loading - * a preset, is that the program should already be in the plugin's - * memory, and can be set instantly (no loading time). - */ -typedef struct clap_event_program { - int32_t channel; // 0..15, -1 unspecified - int32_t bank; // 0..0x7FFFFFFF, -1 unspecified - int32_t program; // 0..0x7FFFFFFF -} clap_event_program; - typedef struct clap_event { clap_event_type type; uint32_t time; // offset from the first sample in the process block @@ -131,7 +114,6 @@ typedef struct clap_event { clap_event_param param; clap_event_time_info time_info; clap_event_chord chord; - clap_event_program program; clap_event_midi midi; clap_event_midi_sysex midi_sysex; }; diff --git a/include/clap/ext/draft/program.h b/include/clap/ext/draft/program.h @@ -1,43 +0,0 @@ -#pragma once - -#ifdef __cplusplus -extern "C" { -#endif - -#include "../../clap.h" - -#define CLAP_EXT_PROGRAM "clap/draft/program" - -typedef struct clap_program_info { - int32_t bank; - int32_t number; - char name[CLAP_NAME_SIZE]; -} clap_program_info; - -// -typedef struct clap_plugin_program { - int32_t (*count)(clap_plugin *plugin); - bool (*get_info)(clap_plugin *plugin, int32_t index, clap_program_info *info); - bool (*clear_program)(clap_plugin *plugin, int32_t bank, int32_t program); - - // Stores the current state into a program - bool (*store_program)(clap_plugin *plugin, int32_t bank, int32_t program, const char *name); - - bool (*rename_program)(clap_plugin *plugin, int32_t bank, int32_t program, const char *name); - - bool (*copy_program)(clap_plugin *plugin, - int32_t src_bank, - int32_t src_program, - int32_t dst_bank, - int32_t dst_program); - - bool (*move_program)(clap_plugin *plugin, - int32_t src_bank, - int32_t src_program, - int32_t dst_bank, - int32_t dst_program); -} clap_plugin_program; - -#ifdef __cplusplus -} -#endif -\ No newline at end of file