We closed this forum 18 June 2010. It has served us well since 2005 as the ALPHA forum did before it from 2002 to 2005. New discussions are ongoing at the new URL http://forum.processing.org. You'll need to sign up and get a new user account. We're sorry about that inconvenience, but we think it's better in the long run. The content on this forum will remain online.
IndexProgramming Questions & HelpSound,  Music Libraries › ProMidi: notes w/ same duration hang
Page Index Toggle Pages: 1
ProMidi: notes w/ same duration hang (Read 281 times)
ProMidi: notes w/ same duration hang
Aug 24th, 2008, 10:24pm
 
It seems that the note played in the last sendNote executed in the following code hangs on for over 50ms. Anyone know why this is happening or how to fix it? I figure it has something to do with the new note buffer dealie where noteOff is sent automatically.

Quote:


import promidi.*;

MidiIO testIO;
MidiOut testOut;
int i = 0;

void setup() {
 
 testIO = MidiIO.getInstance(this);
 testOut = testIO.getMidiOut(0,1);
 
 //testIO.printDevices();
 
}

void draw() {
 
 if(frameCount%120 == 0) {
   //i++;
   testOut.sendNote(new Note(40+(i%32), 100, 50));
   testOut.sendNote(new Note(80+(i%32), 75, 50));
 }
 
}


Page Index Toggle Pages: 1