Package zzub :: Class Plugin
[hide private]
[frames] | no frames]

Class Plugin

source code

object --+
         |
        Plugin

Plugin methods Retreive more details about plugins.

Instance Methods [hide private]
 
__init__(self, handle)
x.__init__(...) initializes x; see x.__class__.__doc__ for signature
source code
 
__hash__(self)
hash(x)
source code
 
__eq__(self, other) source code
 
__ne__(self, other) source code
 
destroy(self)
Deletes a plugin
source code
 
load(self, input)
Load plugin state.
source code
 
save(self, ouput)
Save plugin state.
source code
 
set_name(self, name)
Renames a plugin.
source code
 
get_name(self, maxlen=1024)
Retreive the name of a plugin.
source code
 
get_id(self)
Retreive the unique per-session id of a plugin.
source code
 
get_position(self)
Returns the screen position coordinates for the plugin.
source code
 
set_position(self, x, y)
Sets the plugin screen position.
source code
 
set_position_direct(self, x, y)
Sets the plugin screen position.
source code
 
get_flags(self)
Returns flags for this plugin.
source code
 
get_track_count(self)
Returns the number of tracks.
source code
 
set_track_count(self, count)
Sets the number of tracks.
source code
 
get_group_track_count(self, group)
Returns the number of tracks for one of ParameterGroup
source code
 
get_mute(self)
Returns 1 if plugin is muted, otherwise 0.
source code
 
set_mute(self, muted)
Set whether plugin is muted.
source code
 
get_bypass(self)
Returns 1 if plugin is bypassed, otherwise 0.
source code
 
configure(self, key, value)
Configure a plugin option.
source code
 
set_bypass(self, muted)
Set whether plugin is bypassed.
source code
 
get_commands(self, maxlen=1024)
Returns a string of \-separated command strings
source code
 
get_sub_commands(self, i, maxlen=1024)
When a plugin command string starts with the char '', it has subcommands.
source code
 
command(self, i)
Invoke a command on the plugin.
source code
 
get_pluginloader(self)
Returns the pluginloader used to create this plugin.
source code
 
get_midi_output_device_count(self) source code
 
get_midi_output_device(self, index) source code
 
get_envelope_count(self) source code
 
get_envelope_flags(self, index) source code
 
get_envelope_name(self, index) source code
 
set_stream_source(self, resource) source code
 
set_instrument(self, name)
Sets the plugin instrument (d'oh!)
source code
 
create_pattern(self, rows)
Creates a pattern compatible with given plugin.
source code
 
get_pattern_count(self)
Returns how many patterns are associated with the plugin.
source code
 
add_pattern(self, pattern)
Adds a pattern at the end of the plugins list of patterns
source code
 
remove_pattern(self, pattern)
Remove the pattern from the plugin
source code
 
move_pattern(self, index, newIndex)
Change the order of patterns
source code
 
update_pattern(self, index, pattern)
Replaces pattern contents
source code
 
get_pattern(self, index)
Returns a copy of the requested pattern.
source code
 
get_pattern_list(self) source code
 
get_pattern_by_name(self, name)
Returns the index of the pattern with the given name
source code
 
get_pattern_name(self, index)
Returns the name of given pattern.
source code
 
set_pattern_name(self, index, name)
Updates the name of the pattern.
source code
 
get_pattern_length(self, index)
Returns the length of the pattern.
source code
 
set_pattern_length(self, index, rows)
Updates the number of rows in the pattern.
source code
 
get_pattern_value(self, pattern, group, track, column, row)
Returns a value from the requested pattern.
source code
 
set_pattern_value(self, pattern, group, track, column, row, value)
Sets a value in a pattern.
source code
 
get_new_pattern_name(self, maxLen=1024) source code
 
linear_to_pattern(self, index) source code
 
pattern_to_linear(self, group, track, column) source code
 
get_pattern_column_count(self) source code
 
insert_pattern_rows(self, pattern, column_indices, num_indices, start, rows)
Inserts rows in a pattern.
source code
 
remove_pattern_rows(self, pattern, column_indices, num_indices, start, rows)
Removes rows in a pattern.
source code
 
describe_value(self, group, column, value, maxlen=1024)
Copies columns from an offline pattern to a live pattern.
source code
 
get_parameter_value(self, group, track, column)
Returns the last written value of the requested parameter.
source code
 
set_parameter_value(self, group, track, column, value, record)
Sets the value of a plugin parameter.
source code
 
set_parameter_value_direct(self, group, track, column, value, record)
Sets the value of a plugin parameter.
source code
 
get_parameter_count(self, group, track) source code
 
get_parameter(self, group, track, column) source code
 
get_input_connection_count(self)
Returns the number of input connections for given plugin.
source code
 
get_input_connection_by_type(self, from_plugin, type)
Returns the input connection index for given plugin and connection type.
source code
 
get_input_connection_type(self, index)
Returns the connection type for given plugin and connection index.
source code
 
get_input_connection_plugin(self, index)
Returns the plugin index for given plugin and connection index.
source code
 
get_output_connection_count(self)
Returns the number of output connections for given plugin.
source code
 
get_output_connection_by_type(self, from_plugin, type)
Returns the output connection index for given plugin and connection type.
source code
 
get_output_connection_type(self, index)
Returns the connection type for given plugin and connection index.
source code
 
get_output_connection_plugin(self, index)
Returns the plugin index for given plugin and connection index.
source code
 
add_input(self, from_plugin, type)
Connect two plugins
source code
 
delete_input(self, from_plugin, type)
Disconnect two plugins
source code
 
get_mixbuffer(self)
Copies the given plugins work buffer.
source code
 
get_last_peak(self) source code
 
get_last_worktime(self) source code
 
get_last_cpu_load(self) source code
 
get_last_midi_result(self) source code
 
get_last_audio_result(self) source code
 
invoke_event(self, data, immediate) source code
 
tick(self) source code
 
get_attribute_value(self, index) source code
 
set_attribute_value(self, index, value) source code
 
play_midi_note(self, note, prevNote, velocity) source code
 
play_pattern_row_ref(self, pattern, row) source code
 
play_pattern_row(self, pattern, row) source code
 
set_midi_connection_device(self, from_plugin, name) source code
 
add_event_connection_binding(self, from_plugin, sourceparam, targetgroup, targettrack, targetparam) source code

Inherited from object: __delattr__, __getattribute__, __new__, __reduce__, __reduce_ex__, __repr__, __setattr__, __str__

Class Methods [hide private]
 
_new_from_handle(cls, handle) source code
Static Methods [hide private]
 
create_range_pattern(player, columns, rows)
Creates a non-playable pattern with given columns and rows in group 0, track 0.
source code
Class Variables [hide private]
  _as_parameter_ = None
  _hash = 0
Properties [hide private]

Inherited from object: __class__

Method Details [hide private]

__init__(self, handle)
(Constructor)

source code 

x.__init__(...) initializes x; see x.__class__.__doc__ for signature

Overrides: object.__init__
(inherited documentation)

__hash__(self)
(Hashing function)

source code 

hash(x)

Overrides: object.__hash__
(inherited documentation)

set_name(self, name)

source code 

Renames a plugin. Should fail and return -1 if the name already exists.

get_id(self)

source code 

Retreive the unique per-session id of a plugin. See also zzub_player_get_plugin_by_id().

get_position(self)

source code 

Returns the screen position coordinates for the plugin. Values are expected to be in the range -1..1.

set_position(self, x, y)

source code 

Sets the plugin screen position. Values are expected to be in the range -1..1.

set_position_direct(self, x, y)

source code 

Sets the plugin screen position. Values are expected to be in the range -1..1. This method is not undoable.

get_flags(self)

source code 

Returns flags for this plugin. Shorthand for using zzub_pluginloader_get_flags(). Combined by zero or more values in the zzub_plugin_flag enumeration.

set_track_count(self, count)

source code 

Sets the number of tracks. Will call plugin::set_track_count() from the player thread.

set_mute(self, muted)

source code 

Set whether plugin is muted. 1 for muted, 0 for normal. A muted machine does not produce any sound.

configure(self, key, value)

source code 

Configure a plugin option. this is e.g. used by the recorder plugin to specify a file path to write to.

set_bypass(self, muted)

source code 

Set whether plugin is bypassed. 1 for bypass, 0 for normal. Bypass causes no processing to occur in the given machine.

get_sub_commands(self, i, maxlen=1024)

source code 

When a plugin command string starts with the char '', it has subcommands. Unexpectedly, zzub_plugin_get_sub_commands returns a \-separated string (like get_commands). Some plugins need to be ticked before calling get_sub_commands.

create_range_pattern(player, columns, rows)
Static Method

source code 

Creates a non-playable pattern with given columns and rows in group 0, track 0. All values are set to 0 by default.

create_pattern(self, rows)

source code 

Creates a pattern compatible with given plugin. The pattern becomes incompatible if the plugin has tracks or incoming connections added.

get_pattern(self, index)

source code 

Returns a copy of the requested pattern. Callers must destroy the pattern returned from get_pattern

insert_pattern_rows(self, pattern, column_indices, num_indices, start, rows)

source code 

Inserts rows in a pattern. column_indices has a total length of 3 * num_indices, where each index is a triple of group, track and column.

remove_pattern_rows(self, pattern, column_indices, num_indices, start, rows)

source code 

Removes rows in a pattern. column_indices has a total length of 3 * num_indices, where each index is a triple of group, track and column.

describe_value(self, group, column, value, maxlen=1024)

source code 

Copies columns from an offline pattern to a live pattern. Source and target columns are set up in the mappings array, which has 6 ints for each mapping: group, track and column for source and target plugins. Creates a textual description of the given value. The return value is the number of characters in the output string.

set_parameter_value(self, group, track, column, value, record)

source code 

Sets the value of a plugin parameter. The method will wait for the player thread to pick up the modified value and call process_events().

set_parameter_value_direct(self, group, track, column, value, record)

source code 

Sets the value of a plugin parameter. Unlike zzub_plugin_set_parameter_value(), this method returns immediately. The parameter will be changed later when the player thread notices the modified value. Is also not undoable.