Basic.html does not play WebMIDI
The WebMIDI plugin doesn't seem to be playing (this is on Chrome v50.0.2661.86). It is falling back on WebAudio. This appears to be because the WebMIDI detection code doesn't account for the current Web MIDI API; it looks for .outputs to be either a function or an array, but it is currently a MIDIOutputMap object, and subscripts don't work for accessing values of that type. I think this code will get the first output, if applicable:
output = pluginOutputs.values().next();
if (output) {
output = output.value;
}
This still doesn't fix it, though, because the various output.send() calls pass delay * 1000, and Basic.html passes undefined for several of those delays, and Chrome complains that "The provided double value is non-finite." (presumably because undefined * 1000 is NaN). That's easily remedied by simply passing (delay || 0) * 1000 in place of delay * 1000.
It's still not playing for me, presumably because the WebMIDI branch of the loader code calls the WebMIDI's that doesn't seem to fix it, maybe this is some issue with my particular computer/MIDI setup. That being said, it might be handy to provide some way to allow people to select from MIDI outputs, rather than just using the first one.connect function directly, rather than going through requestQueue() like webaudio and audiotag, which means that the sound font isn't getting loaded.
I want to play more than just one note in BASIC.html. I tried using for next loop but all the notes played at the same time as a chord instead of one at a time like a song.