mirror of
https://github.com/cookiengineer/audacity
synced 2025-06-18 09:00:07 +02:00
157 lines
6.2 KiB
Groff
157 lines
6.2 KiB
Groff
.TH "Plugin library access" 3 "6 Jul 2008" "Version 0.6.0" "SLV2" \" -*- nroff -*-
|
|
.ad l
|
|
.nh
|
|
.SH NAME
|
|
Plugin library access \- An SLV2Instance is an instantiated SLV2Plugin (ie a loaded dynamic library).
|
|
|
|
.PP
|
|
.SS "Functions"
|
|
|
|
.in +1c
|
|
.ti -1c
|
|
.RI "SLV2Instance \fBslv2_plugin_instantiate\fP (SLV2Plugin plugin, double sample_rate, const LV2_Feature *const *features)"
|
|
.br
|
|
.ti -1c
|
|
.RI "void \fBslv2_instance_free\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static const char * \fBslv2_instance_get_uri\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static void \fBslv2_instance_connect_port\fP (SLV2Instance instance, uint32_t port_index, void *data_location)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static void \fBslv2_instance_activate\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static void \fBslv2_instance_run\fP (SLV2Instance instance, uint32_t sample_count)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static void \fBslv2_instance_deactivate\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static const LV2_Descriptor * \fBslv2_instance_get_descriptor\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "static LV2_Handle \fBslv2_instance_get_handle\fP (SLV2Instance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "SLV2UIInstance \fBslv2_ui_instantiate\fP (SLV2Plugin plugin, SLV2UI ui, LV2UI_Write_Function write_function, LV2UI_Controller controller, const LV2_Feature *const *features)"
|
|
.br
|
|
.ti -1c
|
|
.RI "void \fBslv2_ui_instance_free\fP (SLV2UIInstance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "const LV2UI_Descriptor * \fBslv2_ui_instance_get_descriptor\fP (SLV2UIInstance instance)"
|
|
.br
|
|
.ti -1c
|
|
.RI "LV2UI_Handle \fBslv2_ui_instance_get_handle\fP (SLV2UIInstance instance)"
|
|
.br
|
|
.in -1c
|
|
.SH "Detailed Description"
|
|
.PP
|
|
These functions interact with the binary library code only, they do not read data files in any way.
|
|
.SH "Function Documentation"
|
|
.PP
|
|
.SS "SLV2Instance slv2_plugin_instantiate (SLV2Plugin plugin, double sample_rate, const LV2_Feature *const * features)"
|
|
.PP
|
|
Instantiate a plugin.
|
|
.PP
|
|
The returned object represents shared library objects loaded into memory, it must be cleaned up with slv2_instance_free when no longer needed.
|
|
.PP
|
|
\fIplugin\fP is not modified or directly referenced by the returned object (instances store only a copy of the plugin's URI).
|
|
.PP
|
|
\fIhost_features\fP NULL-terminated array of features the host supports. NULL may be passed if the host supports no additional features (unlike the LV2 specification - SLV2 takes care of it).
|
|
.PP
|
|
\fBReturns:\fP
|
|
.RS 4
|
|
NULL if instantiation failed.
|
|
.RE
|
|
.PP
|
|
|
|
.SS "void slv2_instance_free (SLV2Instance instance)"
|
|
.PP
|
|
Free a plugin instance.
|
|
.PP
|
|
\fIinstance\fP is invalid after this call.
|
|
.SS "static const char* slv2_instance_get_uri (SLV2Instance instance)\fC [inline, static]\fP"
|
|
.PP
|
|
Get the URI of the plugin which \fIinstance\fP is an instance of.
|
|
.PP
|
|
Returned string is shared and must not be modified or deleted.
|
|
.SS "static void slv2_instance_connect_port (SLV2Instance instance, uint32_t port_index, void * data_location)\fC [inline, static]\fP"
|
|
.PP
|
|
Connect a port to a data location.
|
|
.PP
|
|
This may be called regardless of whether the plugin is activated, activation and deactivation does not destroy port connections.
|
|
.SS "static void slv2_instance_activate (SLV2Instance instance)\fC [inline, static]\fP"
|
|
.PP
|
|
Activate a plugin instance.
|
|
.PP
|
|
This resets all state information in the plugin, except for port data locations (as set by slv2_instance_connect_port). This MUST be called before calling slv2_instance_run.
|
|
.SS "static void slv2_instance_run (SLV2Instance instance, uint32_t sample_count)\fC [inline, static]\fP"
|
|
.PP
|
|
Run \fIinstance\fP for \fIsample_count\fP frames.
|
|
.PP
|
|
If the hint lv2:hardRtCapable is set for this plugin, this function is guaranteed not to block.
|
|
.SS "static void slv2_instance_deactivate (SLV2Instance instance)\fC [inline, static]\fP"
|
|
.PP
|
|
Deactivate a plugin instance.
|
|
.PP
|
|
Note that to run the plugin after this you must activate it, which will reset all state information (except port connections).
|
|
.SS "static const LV2_Descriptor* slv2_instance_get_descriptor (SLV2Instance instance)\fC [inline, static]\fP"
|
|
.PP
|
|
Get the LV2_Descriptor of the plugin instance.
|
|
.PP
|
|
Normally hosts should not need to access the LV2_Descriptor directly, use the slv2_instance_* functions.
|
|
.PP
|
|
The returned descriptor is shared and must not be deleted.
|
|
.SS "static LV2_Handle slv2_instance_get_handle (SLV2Instance instance)\fC [inline, static]\fP"
|
|
.PP
|
|
Get the LV2_Handle of the plugin instance.
|
|
.PP
|
|
Normally hosts should not need to access the LV2_Handle directly, use the slv2_instance_* functions.
|
|
.PP
|
|
The returned handle is shared and must not be deleted.
|
|
.SS "SLV2UIInstance slv2_ui_instantiate (SLV2Plugin plugin, SLV2UI ui, LV2UI_Write_Function write_function, LV2UI_Controller controller, const LV2_Feature *const * features)"
|
|
.PP
|
|
Instantiate a plugin UI.
|
|
.PP
|
|
The returned object represents shared library objects loaded into memory, it must be cleaned up with slv2_ui_instance_free when no longer needed.
|
|
.PP
|
|
\fIplugin\fP is not modified or directly referenced by the returned object (instances store only a copy of the plugin's URI).
|
|
.PP
|
|
\fIhost_features\fP NULL-terminated array of features the host supports. NULL may be passed if the host supports no additional features (unlike the LV2 specification - SLV2 takes care of it).
|
|
.PP
|
|
\fBReturns:\fP
|
|
.RS 4
|
|
NULL if instantiation failed.
|
|
.RE
|
|
.PP
|
|
|
|
.SS "void slv2_ui_instance_free (SLV2UIInstance instance)"
|
|
.PP
|
|
Free a plugin UI instance.
|
|
.PP
|
|
It is the caller's responsibility to ensure all references to the UI instance (including any returned widgets) are cut before calling this function.
|
|
.PP
|
|
\fIinstance\fP is invalid after this call.
|
|
.SS "LV2UI_Widget slv2_ui_instance_get_widget (SLV2UIInstance instance)"
|
|
.PP
|
|
Get the widget for the UI instance.
|
|
.PP
|
|
.SS "const LV2UI_Descriptor* slv2_ui_instance_get_descriptor (SLV2UIInstance instance)"
|
|
.PP
|
|
Get the LV2UI_Descriptor of the plugin UI instance.
|
|
.PP
|
|
Normally hosts should not need to access the LV2UI_Descriptor directly, use the slv2_ui_instance_* functions.
|
|
.PP
|
|
The returned descriptor is shared and must not be deleted.
|
|
.SS "LV2UI_Handle slv2_ui_instance_get_handle (SLV2UIInstance instance)"
|
|
.PP
|
|
Get the LV2UI_Handle of the plugin UI instance.
|
|
.PP
|
|
Normally hosts should not need to access the LV2UI_Handle directly, use the slv2_ui_instance_* functions.
|
|
.PP
|
|
The returned handle is shared and must not be deleted.
|