plugins/lv2_plugin.h file

LV2 Plugin API.

Contents

Functions

auto lv2_plugin_get_lv2_port_by_symbol(Lv2Plugin* plugin, const char* sym) -> Lv2Port*
Returns the Lv2Port corresponding to the given symbol.
void lv2_ui_write(SuilController controller, uint32_t port_index, uint32_t buffer_size, uint32_t protocol, const void* buffer)
Write from ui.
auto lv2_ui_port_index(SuilController controller, const char* symbol) -> uint32_t
Returns the index of the Lv2Port corresponding to the given symbol.
void lv2_ui_instantiate(Lv2Plugin* plugin, const char* native_ui_type, void* parent)
Instantiates the Lv2Plugin UI.
auto lv2_plugin_run(Lv2Plugin* plugin, const int nframes) -> bool
Runs the plugin for this cycle.
void lv2_allocate_port_buffers(Lv2Plugin* plugin)
Allocate port buffers (only necessary for MIDI).
void lv2_backend_activate_port(Lv2Plugin* plugin, uint32_t port_index)
Expose a port to the system (if applicable) and connect it to its buffer.
auto lv2_create_descriptor_from_lilv(const LilvPlugin* lp) -> PluginDescriptor*
Returns a newly allocated plugin descriptor for the given LilvPlugin if it can be hosted, otherwise NULL.
auto lv2_create_from_uri(Plugin* plugin, const char* uri) -> Lv2Plugin*
Creates an LV2 plugin from given uri.
auto lv2_create_from_state(Plugin* plugin, const char* _path) -> Lv2Plugin*
Creates an LV2 plugin from a state file.
auto lv2_load_from_state(Plugin* plugin) -> Lv2Plugin*
Loads an LV2 plugin from its state file.
auto lv2_instantiate(Lv2Plugin* plugin, char* preset_uri) -> int
Instantiate the plugin.
auto lv2_new(Plugin* plugin) -> Lv2Plugin*
Creates a new LV2 plugin using the given Plugin instance.
void lv2_cleanup(Lv2Plugin* plugin)
TODO.
void lv2_plugin_process(Lv2Plugin* lv2_plugin, const long g_start_frames, const int nframes)
Processes the plugin for this cycle.
auto lv2_plugin_get_latency(Lv2Plugin* pl) -> long
Returns the plugin's latency in samples.
auto lv2_plugin_save_state_to_file(Lv2Plugin* lv2_plugin, const char* dir) -> int
Saves the current state in given dir.
auto lv2_plugin_save_state_to_str(Lv2Plugin* lv2_plugin) -> int
Saves the current state to a string (returned).
void lv2_free(Lv2Plugin* plugin)
Frees the Lv2Plugin.