diff data/model/NoteData.h @ 996:0d3d1ec7dfde

Add MIDI channel to note data and MIDI writer
author Chris Cannam
date Mon, 13 Oct 2014 10:55:43 +0100
parents 59e7fe1b1003
children cc27f35aa75c
line wrap: on
line diff
--- a/data/model/NoteData.h	Mon Oct 13 10:00:54 2014 +0100
+++ b/data/model/NoteData.h	Mon Oct 13 10:55:43 2014 +0100
@@ -23,14 +23,15 @@
 {
     NoteData(int _start, int _dur, int _mp, int _vel) :
 	start(_start), duration(_dur), midiPitch(_mp), frequency(0),
-	isMidiPitchQuantized(true), velocity(_vel) { };
+	isMidiPitchQuantized(true), velocity(_vel), channel(0) { };
             
-    int start;     // audio sample frame
-    int duration;  // in audio sample frames
-    int midiPitch; // 0-127
+    int start;       // audio sample frame
+    int duration;    // in audio sample frames
+    int midiPitch;   // 0-127
     float frequency; // Hz, to be used if isMidiPitchQuantized false
     bool isMidiPitchQuantized;
-    int velocity;  // MIDI-style 0-127
+    int velocity;    // MIDI-style 0-127
+    int channel;     // MIDI 0-15
 
     float getFrequency() const {
         if (isMidiPitchQuantized) {