This site requires JavaScript, please enable it in your browser!
Greenfoot back

Report as inappropriate.

mjrb4
mjrb4 presents ...

2009/1/8

MidiDemo

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.

8309 views / 12 in the last 7 days

1 vote | 0 in the last 7 days

Tags: mouse demo with-source midi

This scenario is a member of: Reusable actors & support classes


open in greenfoot

There is no HTML 5 translation of this scenario available.
View legacy version (requires Java plugin)

This scenarios uses Java features that are not available for use after conversion to HTML 5. Please try the legacy version, which requires the Java plugin to be installed.

It says that it uses a newer version of the greenfoot api, version 2.0.0 but the newest one to download says 1.4.6... where do i download 2.0.0?
mjrb4mjrb4

2009/1/8

Ah, sorry, I'm running the development version of 1.5 at the moment - does it not open at all in 1.4.6?
it complains and then won't compile.
mjrb4mjrb4

2009/1/8

Gimme a minute and I'll reupload in 1.4.6 :)
Thanks!
A new version of this scenario was uploaded on Thu Jan 08 22:47:13 UTC 2009
mjrb4mjrb4

2009/1/8

That should do it :)
A new version of this scenario was uploaded on Fri Mar 06 10:23:40 UTC 2009
DonaldDuckDonaldDuck

2010/10/25

Is it just me, or is greenfoot having problems with midi sequences right now?

Want to leave a comment? You must first log in.

Who likes this?

Builderboy2005