Skip to content

Events

Events are scheduled by passing a dict to Timeline.schedule(), which inspects the keys to figure out what type of event you are intending.

  • Event dicts with a note or degree key are assumed to be note events
  • Event dicts with a control or program_change key are assumed to be control events
  • Event dicts with an action key is assumed to be an action event

The default values for unspecified parameters in an Event dict are infinite patterns generated by PConstant. This means that, unless a finite parameter is explicitly passed, events will continue to be generated forever.

Event types

  • Note events trigger discrete MIDI notes, with a duration and amplitude
  • Control events include MIDI control change, program change and pitchwheel messages, and can apply quasi-continuous control curves
  • Action events call arbitrary Python functions