Report as inappropriate.
Simple demo of using MIDI to play sounds rather than lots of seperate sound files. This has the advantage that you can switch instruments easily, have more control over the notes that are played (e.g. how long they last for) and if you're feeling adventurous even implement things like pitch bending - it's all in the java API already, you just need to call the right methods :) You can do much more than in this example, it was just something I put together very quickly to show how it could be done.
UPDATE: Now added the updated MidiPlayer class used in the MidiPiano scenario.
If you just want the MidiPlayer.java class rather than the whole scenario, just visit the web site link.
6719 views / 4 in the last 7 days
1 vote | 0 in the last 7 days
This scenario is a member of: Reusable actors & support classes
Want to leave a comment? You must first log in.