User Tools

Site Tools


cs276:handelmidi
/*
 *  HandelMIDI
 *
 *  Uses JMEtude to read a MIDI file and play it back on mouse click
 *
 *   -spc, with some help from a long-forgotten example on the web
 */
 
import jmetude.*;
 
Etude handel;
PImage splash;
 
void setup() {
    background(50);
    splash = loadImage("loading.gif");
    noLoop();
    size(splash.width,splash.height);
    handel = new Etude(this);
    handel.createScore("score", "http://arthur.sewanee.edu/scarl/gfhblast.mid");
}
 
void draw() {
  image(splash, 0, 0);
}
 
void mousePressed() {
  handel.playMIDI("score");
}
cs276/handelmidi.txt · Last modified: 2008/11/15 13:57 by scarl