Skip to content

Instantly share code, notes, and snippets.

@charlieroberts
Created February 26, 2012 23:16
Show Gist options
  • Save charlieroberts/1919592 to your computer and use it in GitHub Desktop.
Save charlieroberts/1919592 to your computer and use it in GitHub Desktop.
Using the Seq object in Gibber
s = Synth(); // create a synth
// sequence a four note phrase
seq = Seq(["A4", "B4", "C4", "C#4"], _4);
// tell the sequencer to control the synth. Using introspection,
// the sequencer knows it should call the note method of the
// synth
seq.slave(s);
// Create a sequencer that randomizes the notes found in seq
// at the start of every measure
seq2 = Seq([seq.shuffle], _1);
// Create a sequencer that changes the attack of the synth
// every quarter note
seq3 = Seq([10, 100, 250], _4, "attack");
seq3.slave(s);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment