Module xAutomation
Easy control of parameter automation
.
Requires
xPlayPos
WRITE_MODE |
How to write data into an envelope
INTERLEAVE: leave existing data as-is (renoise default)
PUNCH_IN: remove existing data (using writeahead)
(TODO) LATCH: keep erasing data ahead of play-position |
PLAYMODE |
Envelope interpolation
AUTOMATIC: use existing mode
POINTS: set to points mode
LINEAR: set to linear mode
CUBIC: set to cubic mode |
Functions
-
record (track_idx, param, value, value_mode)
-
Class methods add automation point at current time
Parameters:
- track_idx
(int)
- param
(renoise.DeviceParameter)
- value
(number) the input value
- value_mode
(xMidiMessage.MODE) - apply scaling to the input value
-
has_automation (track_idx, param)
-
check if automation exists for the given parameter
Parameters:
-
clear_range (pos_from, length, ptrack_auto)
-
clear automation for the given range
Parameters:
- pos_from
(int)
- length
(number), can be fractional
- ptrack_auto
(renoise.PatternTrackAutomation)
-
get_position ()
-
retrieve the correct SongPos object according to FOLLOW_MODE
Returns:
int
-
get_or_create_automation (ptrack, param)
-
Static methods get or create the parameter automation
Parameters:
-
get_scaled_value (value, value_mode)
-
Scale an incoming value to the automation range (0-1)
Parameters:
- value
(number)
- value_mode
(xMidiMessage.MODE), abs/rel + #bits
Returns:
number
Tables
-
WRITE_MODE
-
How to write data into an envelope
INTERLEAVE: leave existing data as-is (renoise default)
PUNCH_IN: remove existing data (using writeahead)
(TODO) LATCH: keep erasing data ahead of play-position
Fields:
-
PLAYMODE
-
Envelope interpolation
AUTOMATIC: use existing mode
POINTS: set to points mode
LINEAR: set to linear mode
CUBIC: set to cubic mode
Fields:
- AUTOMATIC
- POINTS
- LINEAR
- CUBIC
Fields
-
self.follow_mode
-
xAutomation.FOLLOW_MODE
-
self.write_mode
-
xAutomation.WRITE_MODE
-
self.playmode
-
renoise.PatternTrackAutomation.PLAYMODE_xx
(leave undefined to use current interpolation mode)
-
self.highres_mode
-
boolean, whether to use fractional line-index or not
-
self.writeahead
-
number, lines that we should clear
(this is automatically computed as tempo changes)