AgsBasePlugin

AgsBasePlugin — The base plugin class

Stability Level

Stable, unless otherwise indicated

Functions

#define AGS_BASE_PLUGIN_GET_OBJ_MUTEX()
GRecMutex * ags_base_plugin_get_obj_mutex ()
gboolean ags_base_plugin_test_flags ()
void ags_base_plugin_set_flags ()
void ags_base_plugin_unset_flags ()
gchar * ags_base_plugin_get_filename ()
void ags_base_plugin_set_filename ()
gchar * ags_base_plugin_get_effect ()
void ags_base_plugin_set_effect ()
guint ags_base_plugin_get_effect_index ()
void ags_base_plugin_set_effect_index ()
gpointer ags_base_plugin_get_plugin_so ()
void ags_base_plugin_set_plugin_so ()
GList * ags_base_plugin_get_plugin_port ()
void ags_base_plugin_set_plugin_port ()
gchar * ags_base_plugin_get_ui_filename ()
void ags_base_plugin_set_ui_filename ()
gchar * ags_base_plugin_get_ui_effect ()
void ags_base_plugin_set_ui_effect ()
guint ags_base_plugin_get_ui_effect_index ()
void ags_base_plugin_set_ui_effect_index ()
gpointer ags_base_plugin_get_ui_plugin_so ()
void ags_base_plugin_set_ui_plugin_so ()
GObject * ags_base_plugin_get_ui_plugin ()
void ags_base_plugin_set_ui_plugin ()
GList * ags_base_plugin_find_filename ()
GList * ags_base_plugin_find_effect ()
GList * ags_base_plugin_find_ui_effect_index ()
gint ags_base_plugin_sort_func ()
GList * ags_base_plugin_sort ()
void ags_base_plugin_apply_port_group_by_prefix ()
gpointer ags_base_plugin_instantiate ()
gpointer ags_base_plugin_instantiate_with_params ()
void ags_base_plugin_connect_port ()
void ags_base_plugin_activate ()
void ags_base_plugin_deactivate ()
void ags_base_plugin_run ()
void ags_base_plugin_load_plugin ()
AgsBasePlugin * ags_base_plugin_new ()

Types and Values

Includes

#include <ags/plugin/ags_base_plugin.h>

Description

The AgsBasePlugin loads/unloads plugins on a abstraction level.

Functions

AGS_BASE_PLUGIN_GET_OBJ_MUTEX()

#define AGS_BASE_PLUGIN_GET_OBJ_MUTEX(obj) (&(((AgsBasePlugin *) obj)->obj_mutex))

ags_base_plugin_get_obj_mutex ()

GRecMutex *
ags_base_plugin_get_obj_mutex (AgsBasePlugin *base_plugin);

Get object mutex.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the GRecMutex to lock base_plugin

Since: 3.1.0


ags_base_plugin_test_flags ()

gboolean
ags_base_plugin_test_flags (AgsBasePlugin *base_plugin,
                            guint flags);

Test flags to be set on recall .

Parameters

base_plugin

the AgsBasePlugin

 

flags

the flags

 

Returns

TRUE if flags are set, else FALSE

Since: 3.0.0


ags_base_plugin_set_flags ()

void
ags_base_plugin_set_flags (AgsBasePlugin *base_plugin,
                           guint flags);

Set flags.

Parameters

base_plugin

the AgsBasePlugin

 

flags

the flags

 

Since: 3.0.0


ags_base_plugin_unset_flags ()

void
ags_base_plugin_unset_flags (AgsBasePlugin *base_plugin,
                             guint flags);

Unset flags.

Parameters

base_plugin

the AgsBasePlugin

 

flags

the flags

 

Since: 3.0.0


ags_base_plugin_get_filename ()

gchar *
ags_base_plugin_get_filename (AgsBasePlugin *base_plugin);

Get filename.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the filename

Since: 3.1.0


ags_base_plugin_set_filename ()

void
ags_base_plugin_set_filename (AgsBasePlugin *base_plugin,
                              gchar *filename);

Set filename.

Parameters

base_plugin

the AgsBasePlugin

 

filename

the filename

 

Since: 3.1.0


ags_base_plugin_get_effect ()

gchar *
ags_base_plugin_get_effect (AgsBasePlugin *base_plugin);

Get effect.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the effect

Since: 3.1.0


ags_base_plugin_set_effect ()

void
ags_base_plugin_set_effect (AgsBasePlugin *base_plugin,
                            gchar *effect);

Set effect.

Parameters

base_plugin

the AgsBasePlugin

 

effect

the effect

 

Since: 3.1.0


ags_base_plugin_get_effect_index ()

guint
ags_base_plugin_get_effect_index (AgsBasePlugin *base_plugin);

Get effect index.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the effect index

Since: 3.1.0


ags_base_plugin_set_effect_index ()

void
ags_base_plugin_set_effect_index (AgsBasePlugin *base_plugin,
                                  guint effect_index);

Set effect index.

Parameters

base_plugin

the AgsBasePlugin

 

effect_index

the effect index

 

Since: 3.1.0


ags_base_plugin_get_plugin_so ()

gpointer
ags_base_plugin_get_plugin_so (AgsBasePlugin *base_plugin);

Get plugin so.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the plugin so

Since: 3.1.0


ags_base_plugin_set_plugin_so ()

void
ags_base_plugin_set_plugin_so (AgsBasePlugin *base_plugin,
                               gpointer plugin_so);

Set plugin_so.

Parameters

base_plugin

the AgsBasePlugin

 

plugin_so

the plugin so

 

Since: 3.1.0


ags_base_plugin_get_plugin_port ()

GList *
ags_base_plugin_get_plugin_port (AgsBasePlugin *base_plugin);

ags_base_plugin_set_plugin_port ()

void
ags_base_plugin_set_plugin_port (AgsBasePlugin *base_plugin,
                                 GList *plugin_port);

Set recall dependency by replacing existing.

Parameters

base_plugin

the AgsBasePlugin

 

plugin_port

the GList containing AgsPluginPort.

[element-type AgsAudio.PluginPort][transfer full]

Since: 3.1.0


ags_base_plugin_get_ui_filename ()

gchar *
ags_base_plugin_get_ui_filename (AgsBasePlugin *base_plugin);

Get UI filename.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the UI filename

Since: 3.1.0


ags_base_plugin_set_ui_filename ()

void
ags_base_plugin_set_ui_filename (AgsBasePlugin *base_plugin,
                                 gchar *ui_filename);

Set UI filename.

Parameters

base_plugin

the AgsBasePlugin

 

ui_filename

the UI filename

 

Since: 3.1.0


ags_base_plugin_get_ui_effect ()

gchar *
ags_base_plugin_get_ui_effect (AgsBasePlugin *base_plugin);

Get UI effect.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the UI effect

Since: 3.1.0


ags_base_plugin_set_ui_effect ()

void
ags_base_plugin_set_ui_effect (AgsBasePlugin *base_plugin,
                               gchar *ui_effect);

Set UI effect.

Parameters

base_plugin

the AgsBasePlugin

 

ui_effect

the UI effect

 

Since: 3.1.0


ags_base_plugin_get_ui_effect_index ()

guint
ags_base_plugin_get_ui_effect_index (AgsBasePlugin *base_plugin);

Get UI effect index.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the UI effect index

Since: 3.1.0


ags_base_plugin_set_ui_effect_index ()

void
ags_base_plugin_set_ui_effect_index (AgsBasePlugin *base_plugin,
                                     guint ui_effect_index);

Set UI effect index.

Parameters

base_plugin

the AgsBasePlugin

 

ui_effect_index

the UI effect index

 

Since: 3.1.0


ags_base_plugin_get_ui_plugin_so ()

gpointer
ags_base_plugin_get_ui_plugin_so (AgsBasePlugin *base_plugin);

Get plugin so.

Parameters

base_plugin

the AgsBasePlugin

 

Returns

the plugin so

Since: 3.1.0


ags_base_plugin_set_ui_plugin_so ()

void
ags_base_plugin_set_ui_plugin_so (AgsBasePlugin *base_plugin,
                                  gpointer ui_plugin_so);

Set ui_plugin_so.

Parameters

base_plugin

the AgsBasePlugin

 

ui_plugin_so

the plugin so

 

Since: 3.1.0


ags_base_plugin_get_ui_plugin ()

GObject *
ags_base_plugin_get_ui_plugin (AgsBasePlugin *base_plugin);

ags_base_plugin_set_ui_plugin ()

void
ags_base_plugin_set_ui_plugin (AgsBasePlugin *base_plugin,
                               GObject *ui_plugin);

ags_base_plugin_find_filename ()

GList *
ags_base_plugin_find_filename (GList *base_plugin,
                               gchar *filename);

Find filename in base_plugin GList of AgsBasePlugin.

Parameters

base_plugin

the GList containing AgsBasePlugin.

[element-type AgsAudio.BasePlugin]

filename

the filename as string

 

Returns

the next matching GList.

[element-type AgsAudio.BasePlugin][transfer none]

Since: 3.0.0


ags_base_plugin_find_effect ()

GList *
ags_base_plugin_find_effect (GList *base_plugin,
                             gchar *filename,
                             gchar *effect);

Find filename and effect in base_plugin GList of AgsBasePlugin.

Parameters

base_plugin

the GList containing AgsBasePlugin.

[element-type AgsAudio.BasePlugin]

filename

the filename as string

 

effect

the effect as string

 

Returns

the next matching GList.

[element-type AgsAudio.BasePlugin][transfer none]

Since: 3.0.0


ags_base_plugin_find_ui_effect_index ()

GList *
ags_base_plugin_find_ui_effect_index (GList *base_plugin,
                                      gchar *ui_filename,
                                      guint ui_effect_index);

Find ui_filename and ui_effect_index in base_plugin GList of AgsBasePlugin.

Parameters

base_plugin

the GList containing AgsBasePlugin.

[element-type AgsAudio.BasePlugin]

ui_filename

the UI filename as string

 

ui_effect_index

the UI effect index

 

Returns

the next matching GList.

[element-type AgsAudio.BasePlugin][transfer none]

Since: 3.0.0


ags_base_plugin_sort_func ()

gint
ags_base_plugin_sort_func (gpointer a,
                           gpointer b);

Sort function.

Parameters

a

a AgsBasePlugin

 

b

an other AgsBasePlugin

 

Returns

a value smaller to, equal to or greater to 0 like strcmp

Since: 3.0.0


ags_base_plugin_sort ()

GList *
ags_base_plugin_sort (GList *base_plugin);

Sort base_plugin alphabetically.

Parameters

base_plugin

the GList containing AgsBasePlugin.

[element-type AgsAudio.BasePlugin][transfer none]

Returns

the sorted GList.

[element-type AgsAudio.BasePlugin][transfer none]

Since: 3.0.0


ags_base_plugin_apply_port_group_by_prefix ()

void
ags_base_plugin_apply_port_group_by_prefix
                               (AgsBasePlugin *base_plugin);

ags_base_plugin_instantiate ()

gpointer
ags_base_plugin_instantiate (AgsBasePlugin *base_plugin,
                             guint samplerate,
                             guint buffer_size);

Instantiate the plugin

Parameters

base_plugin

the AgsBasePlugin

 

samplerate

the samplerate

 

buffer_size

the fixed buffer size

 

Returns

the new plugin instance handle

Since: 3.0.0


ags_base_plugin_instantiate_with_params ()

gpointer
ags_base_plugin_instantiate_with_params
                               (AgsBasePlugin *base_plugin,
                                guint *n_params,
                                gchar ***parameter_name,
                                GValue **value);

Instantiate the plugin

Parameters

base_plugin

the AgsBasePlugin

 

n_params

guint pointer to parameter count

 

parameter_name

string vector containing parameter names

 

value

the GValue array

 

Returns

the new plugin instance handle

Since: 3.0.0


ags_base_plugin_connect_port ()

void
ags_base_plugin_connect_port (AgsBasePlugin *base_plugin,
                              gpointer plugin_handle,
                              guint port_index,
                              gpointer data_location);

Connect a plugin instance.

Parameters

base_plugin

the AgsBasePlugin

 

plugin_handle

the plugin instance handle

 

port_index

the port's index to connect

 

data_location

the data location to connect

 

Since: 3.0.0


ags_base_plugin_activate ()

void
ags_base_plugin_activate (AgsBasePlugin *base_plugin,
                          gpointer plugin_handle);

Activate a plugin instance

Parameters

base_plugin

the AgsBasePlugin

 

plugin_handle

the plugin instance handle

 

Since: 3.0.0


ags_base_plugin_deactivate ()

void
ags_base_plugin_deactivate (AgsBasePlugin *base_plugin,
                            gpointer plugin_handle);

Deactivat a plugin instance

Parameters

base_plugin

the AgsBasePlugin

 

plugin_handle

the plugin instance handle

 

Since: 3.0.0


ags_base_plugin_run ()

void
ags_base_plugin_run (AgsBasePlugin *base_plugin,
                     gpointer plugin_handle,
                     snd_seq_event_t *seq_event,
                     guint frame_count);

Deactivat a plugin instance

Parameters

base_plugin

the AgsBasePlugin

 

plugin_handle

the plugin instance handle

 

seq_event

the alsa sequencer events.

[type gpointer][transfer none]

frame_count

the frame counts

 

Since: 3.0.0


ags_base_plugin_load_plugin ()

void
ags_base_plugin_load_plugin (AgsBasePlugin *base_plugin);

Load the plugin

Parameters

base_plugin

the AgsBasePlugin

 

Since: 3.0.0


ags_base_plugin_new ()

AgsBasePlugin *
ags_base_plugin_new (gchar *filename,
                     gchar *effect,
                     guint effect_index);

Creates an AgsBasePlugin

Parameters

filename

the plugin .so

 

effect

the effect's string representation

 

effect_index

the effect's index

 

Returns

a new AgsBasePlugin

Since: 3.0.0

Types and Values

enum AgsBasePluginFlags

Enum values to control the behavior or indicate internal state of AgsBasePlugin by enable/disable as flags.

Members

AGS_BASE_PLUGIN_IS_INSTRUMENT

plugin is instrument