X-Git-Url: https://main.carlh.net/gitweb/?a=blobdiff_plain;f=libs%2Fardour%2Fardour%2Flv2_plugin.h;h=6b4b1a1c67461e073cd2c8f169a0349e20a1b67e;hb=ff9e1dfe602ab7b54d49849373fb2ce265c4f4a0;hp=a4b89a5841ca922bb0a9dbd06ae0f0421e815f93;hpb=4c5ef5318edb4e1cdc76288860c27358155efe17;p=ardour.git diff --git a/libs/ardour/ardour/lv2_plugin.h b/libs/ardour/ardour/lv2_plugin.h index a4b89a5841..6b4b1a1c67 100644 --- a/libs/ardour/ardour/lv2_plugin.h +++ b/libs/ardour/ardour/lv2_plugin.h @@ -29,6 +29,8 @@ #include "ardour/worker.h" #include "pbd/ringbuffer.h" +typedef struct LV2_Evbuf_Impl LV2_Evbuf; + namespace ARDOUR { // a callback function for lilv_state_new_from_instance(). friend of LV2Plugin @@ -75,6 +77,7 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee const void* c_ui_type(); bool is_external_ui () const; + bool is_external_kx () const; bool ui_is_resizable () const; const char* port_symbol (uint32_t port) const; @@ -122,7 +125,7 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee bool has_editor () const; bool has_message_output () const; - void write_from_ui(uint32_t index, + bool write_from_ui(uint32_t index, uint32_t protocol, uint32_t size, const uint8_t* body); @@ -179,7 +182,6 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee float* _bpm_control_port; ///< Special input set by ardour float* _freewheel_control_port; ///< Special input set by ardour float* _latency_control_port; ///< Special output set by ardour - uint32_t _position_seq_port_idx; ///< Index of Sequence port for position framepos_t _next_cycle_start; ///< Expected start frame of next run cycle double _next_cycle_speed; ///< Expected start frame of next run cycle PBD::ID _insert_id; @@ -190,18 +192,20 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee uint32_t* type); typedef enum { - PORT_INPUT = 1, - PORT_OUTPUT = 1 << 1, - PORT_AUDIO = 1 << 2, - PORT_CONTROL = 1 << 3, - PORT_EVENT = 1 << 4, - PORT_MESSAGE = 1 << 5, - PORT_ATOM = 1 << 6 + PORT_INPUT = 1, ///< Input port + PORT_OUTPUT = 1 << 1, ///< Output port + PORT_AUDIO = 1 << 2, ///< Audio (buffer of float) + PORT_CONTROL = 1 << 3, ///< Control (single float) + PORT_EVENT = 1 << 4, ///< Old event API event port + PORT_SEQUENCE = 1 << 5, ///< New atom API event port + PORT_MIDI = 1 << 6, ///< Event port understands MIDI + PORT_POSITION = 1 << 7 ///< Event port understands position } PortFlag; typedef unsigned PortFlags; std::vector _port_flags; + std::vector _port_minimumSize; std::map _port_indices; /// Message send to/from UI via ports @@ -211,12 +215,12 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee uint32_t size; }; - void write_to_ui(uint32_t index, + bool write_to_ui(uint32_t index, uint32_t protocol, uint32_t size, const uint8_t* body); - void write_to(RingBuffer* dest, + bool write_to(RingBuffer* dest, uint32_t index, uint32_t protocol, uint32_t size, @@ -237,6 +241,7 @@ class LV2Plugin : public ARDOUR::Plugin, public ARDOUR::Workee LV2_Feature _log_feature; LV2_Feature _work_schedule_feature; LV2_Feature _options_feature; + LV2_Feature _def_state_feature; // Options passed to plugin int32_t _block_length;