예제 #1
0
 public void programs(int theID) {
   switch (theID) {
     case (0):
       MIDIThread.mode(0); // oscillation mode
       break;
     case (1):
       MIDIThread.mode(1); // on mode
       break;
     case (2):
       MIDIThread.mode(2); // off mode
       break;
     case (3):
       MIDIThread.mode(3); // random mode
       break;
     case (4):
       MIDIThread.mode(4); // random mode
       break;
   }
 }
예제 #2
0
 public void setup() {
   size(490, 260, OPENGL);
   background(0);
   smooth();
   GUISetup();
   MIDIThread = new SimpleThread("midi");
   MIDIThread.start();
   int[] light = new int[12];
   for (int k = 0; k < 11; k++) {
     softLight[k] = 0;
   }
 }
예제 #3
0
 public void noteOff(int channel, int pitch, int velocity) {
   if (translator) {
     MIDIThread.MIDILightIn(pitch, 0);
   }
 }
예제 #4
0
 public void controllerChange(int channel, int number, int value) {
   MIDIThread.MIDILightIn(number, value);
 }