clap

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

commit d0020ba148c60deed6fd368508cd7aa32f2d14d2
parent 08fdba94d815379d013c55c22cb942907f176474
Author: Alexandre Bique <bique.alexandre@gmail.com>
Date:   Tue, 18 Nov 2014 00:06:18 +0100

Moving unrequired bits from plugin to extension

Diffstat:
Ainclude/clap/clap-gui.h | 15+++++++++++++++
Ainclude/clap/clap-state.h | 17+++++++++++++++++
Minclude/clap/clap.h | 10----------
3 files changed, 32 insertions(+), 10 deletions(-)

diff --git a/include/clap/clap-gui.h b/include/clap/clap-gui.h @@ -0,0 +1,15 @@ +#ifndef CLAP_GUI_H +# define CLAP_GUI_H + +# include "clap.h" + +# define CLAP_EXT_GUI "clap/gui" + +struct clap_plugin_gui +{ + /* gui */ + bool (*open_gui)(struct clap_plugin *plugin); + void (*close_gui)(struct clap_plugin *plugin); +}; + +#endif /* !CLAP_GUI_H */ diff --git a/include/clap/clap-state.h b/include/clap/clap-state.h @@ -0,0 +1,17 @@ +#ifndef CLAP_STATE_H +# define CLAP_STATE_H + +# include "clap.h" + +# define CLAP_EXT_STATE "clap/state" + +struct clap_plugin_state +{ + /* The plugin has to allocate and save its state into *buffer. + * The plugin is also responsible to free the buffer on the + * next call to save() or when the plugin is destroyed. */ + bool (*save)(struct clap_plugin *plugin, void **buffer, uint32_t *size); + bool (*restore)(struct clap_plugin *plugin, const void *buffer, uint32_t size); +}; + +#endif /* !CLAP_STATE_H */ diff --git a/include/clap/clap.h b/include/clap/clap.h @@ -285,16 +285,6 @@ struct clap_plugin enum clap_process_status (*process)(struct clap_plugin *plugin, struct clap_process *process); - /* gui */ - bool (*open_gui)(struct clap_plugin *plugin); - void (*close_gui)(struct clap_plugin *plugin); - - /* The plugin has to allocate and save its state into *buffer. - * The plugin is also responsible to free the buffer on the - * next call to save() or when the plugin is destroyed. */ - bool (*save)(struct clap_plugin *plugin, void **buffer, uint32_t *size); - bool (*restore)(struct clap_plugin *plugin, const void *buffer, uint32_t size); - /* future features */ void *(*extension)(struct clap_plugin *plugin, const char *id); };