19 #ifndef __SLV2_PLUGININSTANCE_H__
20 #define __SLV2_PLUGININSTANCE_H__
29 #include "slv2/plugin.h"
30 #include "slv2/port.h"
32 typedef struct _InstanceImpl* SLV2InstanceImpl;
44 typedef struct _Instance {
45 const LV2_Descriptor* lv2_descriptor;
46 LV2_Handle lv2_handle;
47 SLV2InstanceImpl pimpl;
80 const LV2_Feature*
const* features);
90 #ifndef LIBSLV2_SOURCE
96 static inline const char*
99 return instance->lv2_descriptor->URI;
113 instance->lv2_descriptor->connect_port
114 (instance->lv2_handle, port_index, data_location);
127 if (instance->lv2_descriptor->activate)
128 instance->lv2_descriptor->activate(instance->lv2_handle);
139 uint32_t sample_count)
142 instance->lv2_descriptor->run(instance->lv2_handle, sample_count);
154 if (instance->lv2_descriptor->deactivate)
155 instance->lv2_descriptor->deactivate(instance->lv2_handle);
164 static inline const void*
168 if (instance->lv2_descriptor->extension_data)
169 return instance->lv2_descriptor->extension_data(uri);
182 static inline const LV2_Descriptor*
185 return instance->lv2_descriptor;
196 static inline LV2_Handle
199 return instance->lv2_handle;