Following up on my post about Controlling Flash with a Monome, I’ve done a bit more research on the ways to get controller data in and out of Flash.
My current conclusion: Oscar for OSC, Red5 for MIDI. Read on for the details.
In Short: OSC to Flash, one-way, Mac-only.
Details: The slickest of the controller translation apps, this one is great for connecting up the Monome and any other controllers that support OSC natively. Additionally, if none of the MIDI solutions are working for your setup, you can convert your MIDI to OSC using Quartz Composer and then route it through Oscar and into Flash. Perhaps a forthcoming post on this?
In Short: Open source Flash Server, includes MIDI functions.
Details: This Java server supports streaming audio, video, and lots of extra stuff. It seems like it’s perhaps overkill if you just want to get MIDI into flash, but hey, it works! The newest stable release (0.8) is available for OSX, Windows, or as source to build on your own box. Unfortunately, the Mac 0.8 installable version needs Java 1.6, which was never released for 32-bit Mac systems. Thankfully, you can download the 0.6 release pre-compiled, and it works just fine. Last updated June 2009.
Starter Code: Lukasz Karluk put together a great starting point: AS3 Code for Red5
In Short: A Java applet and bridge that enables MIDI input into Flash, including through a webserver.
Details: I really wish I could have gotten this to work. He’s got an online example that worked for me, but I couldn’t get my local version to connect properly. After messing about with it, I can no longer get his example to see my MIDI messages either (though my devices still show up properly). To be fair, I updated my OS in between the working and not-working tries, so it could be that, or something else I messed up. Let me know if you’ve had success with this project – there’s lots of possibility for fun multi-player MIDI games here.
In Short: MIDI input and output from Flash, last updated 2005.
Details: Assumed abandoned, this was a plug-in based on some sort of undocumented feature. It allowed MIDI control, as well as playback of MIDI files. It was mostly Windows-Only, though there was an Alpha version of a Mac plug-in made.
In Short: Max/MSP external allows bi-directional communication- last updated 2006
Details: Assumed abandoned, this was an external for Max/MSP (so you need to write a Max/MSP program that would use it). Mac and PC versions still available for download, current compatibility unknown (written for Flash 5).
In Short: A Java server that creates a bi-directional channel for communication between OSC devices and Flash.
Details: I did get it working, but Oscar is much slicker. If you’re on a PC, this is a great (perhaps the only) solution for OSC to Flash communication. There’s a new flOSC by tranxete, but like Red5 0.8, it requires Java 1.6, so it’s a non-starter for me.
Starter Code: From tim, based on the fwiidom classes: flOSC As3 Classes.
Tim, of the flOSC classes above, also has a good round-up on using MIDI in Flash.