Tables

Tables define the behavior of an instrument over time.

Each table consists of a list of volume envelopes, transposes and effect commands. How (or whether) these commands are applied to an instrument depends on that instrument’s settings.

Usage Examples

# Get table $4 from the song's table of tables
table = song.tables[0x4]

# Alternatively, get it from instrument $b
table = song.instruments[0xb].table

# Set the envelope in row $5 to $A6
table.envelopes[0x5] = 0xa6

# Set the value of the first effect's parameter to 5 in row $6
table.fx1[0x6].value = 5

API Reference

class pylsdj.Table(song, index)

Each table is a sequence of transposes, commands, and amplitude changes that can be applied to any channel.

envelopes

a list of the table’s volume envelopes

fx1

a list of the table’s first effects, represented as TableFX objects

fx2

a list of the table’s first effects, represented as TableFX objects

index

the table’s index within its parent song’s table of macro tables

song

the table’s parent Song

transposes

a list of the table’s volume transposes

class pylsdj.TableFX(params, table_index, fx_index)
command

the effect’s command

value

the command’s parameter