quantum-entangler 0.1.1

Rhythm as Code
Documentation
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
extern crate quantum_entangler;

fn main() {
  // The config cycle is how the pattern should be triggered
  // 4 is the often the trigger occurs
  // The trigger occurs every 4 notes played
  let trigger = "cycle|4".to_string();

  // random is the pattern for selecting which previous played notes should be played when the pattern is triggered
  // The next config is a list of numbers 1-9 defining the note value that should be triggered: 
  // 4 => Quarter Note, 8 => 8th Note, 3 => Quarter Note Triplet
  let pattern = "random|4,4,4,5,5,2,2,3,3,3,3,6,6,6,4,4,8,8,8,8,4,4,9,9,9,9".to_string();
  
  match quantum_entangler::midi::setup::intercept(trigger, pattern) {
      Ok(_) => (),
      Err(err) => println!("Error: {}", err)
  }
}