-
Notifications
You must be signed in to change notification settings - Fork 645
Open
Description
I'd like to play several midi-files after one another, like sort of a playlist. According to the midi-file I'd like to get all its instruments to play. Sofar I only achieve that like this:
var player;
var instruments;
window.onload = function () {
MIDI.loadPlugin({
soundfontUrl: './soundfont/',
onsuccess: function () {
player = MIDI.Player;
player.timeWrap = 1;
player.loadFile('test.mid', function () {
instruments = player.getFileInstruments();
for (var i = 0; i < instruments.length; i++) {
MIDI.programChange(i, MIDI.GM.byName[instruments[i]].number);
}
player.start();
});
}
});
};
However they either seem to play on the wrong channel or somehow the wrong soundfont is assigned. So for example, the clarinet plays the piano's melody. I couldn't figure out how to solve that problem.
I'd be really happy about some advice or ideas :)
Metadata
Metadata
Assignees
Labels
No labels