Module xLinePattern

This class represents a 'virtual' renoise.PatternLine .

See also: xLine xLinePattern

Functions

__init (note_columns, effect_columns) [Constructor], accepts two arguments for initializing the class
apply_descriptor (note_columns, effect_columns) [Class] Convert descriptors into class instances (empty tables are left as-is)
do_write (sequence, line, track_idx, phrase, tokens, include_hidden, expand_columns, clear_undefined) [Class] Combined method for writing to pattern or phrase
process_columns (rns_columns, rns_track_or_phrase, xline_columns, include_hidden, expand_columns, visible_cols, tokens, clear_undefined, col_type) [Class] Write to either note or effect column
do_read (rns_line, max_note_cols, max_fx_cols) [Static] Read from pattern, return note/effect-column descriptors
get_effect_command (track, line, fx_type, notecol_idx, visible_only) [Static] Look for a specific type of effect command in line, return all matches (the number of characters in 'fx_type' decides if we search columns or sub-columns)
get_effect_subcolumn_command (track, line, fx_type, notecol_idx, visible_only) [Static] Get effect command using single-digit syntax (sub-column) (look through vol/pan subcolumns in note-columns)
get_effect_column_command (track, line, fx_type, notecol_idx, visible_only) [Static] Get effect command using two-digit syntax (effect-column) (look through note effect-columns and effect-columns)
get_available_effect_column (track, line, visible_only, from_column) Get the first available effect column
set_effect_column_command (track, line, fx_number, fx_amount, column_index, overwrite) Write command into effect-column or note-effects column - does the following * check if effect-command already is present in effect columns * check if it needs to allocate new effect-columns (when existing ones are occupied)
get_midi_command (track, line) [Static] Get midi command from line (look in last note-column, panning + first effect column)
set_midi_command (track, line, cmd, expand, replace) [Static] Set midi command (write to pattern)
clear_midi_command (track, line) [Static] Clear previously set midi command.

Tables

COLUMN_TYPES enum, defines the available column types
EFFECT_CHARS table, supported effect characters

Fields

MAX_NOTE_COLUMNS number, maximum number of note columns
MAX_EFFECT_COLUMNS number, maximum number of effect columns
EMPTY_VALUE number, constant value used for representing empty values
EMPTY_STRING string, constant value used for representing empty values
self.effect_columns table


Functions

__init (note_columns, effect_columns)
[Constructor], accepts two arguments for initializing the class

Parameters:

  • note_columns (table, xNoteColumn descriptor)
  • effect_columns (table, xEffectColumn descriptor)
apply_descriptor (note_columns, effect_columns)
[Class] Convert descriptors into class instances (empty tables are left as-is)

Parameters:

  • note_columns (xNoteColumn or table)
  • effect_columns (xEffectColumn or table)
do_write (sequence, line, track_idx, phrase, tokens, include_hidden, expand_columns, clear_undefined)
[Class] Combined method for writing to pattern or phrase

Parameters:

  • sequence (int)
  • line (int)
  • track_idx (int), when writing to pattern
  • phrase (renoise.InstrumentPhrase), when writing to phrase
  • tokens (table) process these tokens ("note_value", etc)
  • include_hidden (bool) apply to hidden columns as well
  • expand_columns (bool) reveal columns as they are written to
  • clear_undefined (bool) clear existing data when ours is nil
process_columns (rns_columns, rns_track_or_phrase, xline_columns, include_hidden, expand_columns, visible_cols, tokens, clear_undefined, col_type)
[Class] Write to either note or effect column

Parameters:

  • rns_columns (array)
  • rns_track_or_phrase (renoise.Track or renoise.InstrumentPhrase)
  • xline_columns (table)
  • include_hidden (bool) apply to hidden columns as well
  • expand_columns (bool) reveal columns as they are written to
  • visible_cols (int) number of visible note/effect columns
  • tokens (table) process these tokens ("note_value", etc)
  • clear_undefined (bool) clear existing data when ours is nil
  • col_type (xLinePattern.COLUMN_TYPES)
do_read (rns_line, max_note_cols, max_fx_cols)
[Static] Read from pattern, return note/effect-column descriptors

Parameters:

  • rns_line (renoise.PatternLine)
  • max_note_cols (int)
  • max_fx_cols (int)

Returns:

  1. table, note columns
  2. table, effect columns
get_effect_command (track, line, fx_type, notecol_idx, visible_only)
[Static] Look for a specific type of effect command in line, return all matches (the number of characters in 'fx_type' decides if we search columns or sub-columns)

Parameters:

  • track (renoise.Track)
  • line (renoise.PatternLine)
  • fx_type (number), e.g. "0S" or "B"
  • notecol_idx (number), note-column index
  • visible_only ] (boolean), restrict search to visible columns in track

Returns:

    table<{ columnindex: note/effect column index (across visible columns) columntype: xEffectColumn.TYPE amountvalue: number amountstring: string }> or nil
get_effect_subcolumn_command (track, line, fx_type, notecol_idx, visible_only)
[Static] Get effect command using single-digit syntax (sub-column) (look through vol/pan subcolumns in note-columns)

Parameters:

  • track
  • line
  • fx_type
  • notecol_idx
  • visible_only
get_effect_column_command (track, line, fx_type, notecol_idx, visible_only)
[Static] Get effect command using two-digit syntax (effect-column) (look through note effect-columns and effect-columns)

Parameters:

  • track (renoise.Track)
  • line (renoise.PatternLine)
  • fx_type (string), two-digit string, e.g. "0S"
  • notecol_idx ] (number), restrict search to this note-column
  • visible_only ] (boolean), restrict search to visible note/effect-columns

Returns:

    table - see geteffectcommand()
get_available_effect_column (track, line, visible_only, from_column)
Get the first available effect column

Parameters:

  • track (renoise.Track)
  • line (renoise.PatternLine)
  • visible_only ] (boolean), restrict search to visible columns in track
  • from_column ] (number), which column to start search from

Returns:

    {

    column_index: number, note/effect column index (across visible columns)
    column_type: xEffectColumn.TYPE
    

    }

set_effect_column_command (track, line, fx_number, fx_amount, column_index, overwrite)
Write command into effect-column or note-effects column - does the following * check if effect-command already is present in effect columns * check if it needs to allocate new effect-columns (when existing ones are occupied)

Parameters:

  • track (renoise.Track)
  • line (renoise.PatternLine)
  • fx_number (string) - two-digit string
  • fx_amount (number) - fx value
  • column_index ] (number) - column index (visible note-columns -> effect columns)
  • overwrite ] (boolean) - replace existing value (only when column_index is specified)

Returns:

  1. renoise.NoteColumn/renoise.EffectColumn when command was written, else nil
  2. string, error message when unable to write
get_midi_command (track, line)
[Static] Get midi command from line (look in last note-column, panning + first effect column)

Parameters:

  • track
  • line

Returns:

    xMidiCommand or nil if not found
set_midi_command (track, line, cmd, expand, replace)
[Static] Set midi command (write to pattern)

Parameters:

  • track renoise.Track
  • line renoise.PatternLine
  • cmd xMidiCommand
  • expand ] boolean, show target panning/effect-column (default is true)
  • replace ] boolean, replace existing commands (default is false - push to side)
clear_midi_command (track, line)
[Static] Clear previously set midi command.

Parameters:

  • track renoise.Track
  • line renoise.PatternLine

Tables

COLUMN_TYPES
enum, defines the available column types

Fields:

  • NOTE_COLUMN
  • EFFECT_COLUMN
EFFECT_CHARS
table, supported effect characters

Fields:

  • 0
  • 1
  • 2
  • 3
  • 4
  • 5
  • 6
  • 7
  • 8
  • 9
  • A
  • B
  • C
  • D
  • E
  • F
  • G
  • H
  • I
  • J
  • K
  • L
  • M
  • N
  • O
  • P
  • Q
  • R
  • S
  • T
  • U
  • V
  • W
  • X
  • Y
  • Z

Fields

MAX_NOTE_COLUMNS
number, maximum number of note columns
MAX_EFFECT_COLUMNS
number, maximum number of effect columns
EMPTY_VALUE
number, constant value used for representing empty values
EMPTY_STRING
string, constant value used for representing empty values
self.effect_columns
table
generated by LDoc 1.4.2