6 ANGRY MEN - Header TECHNICAL DESIGN COMMUNICATION INTERACTION 6ANGRYMEN WHO ARE WE BLOG

Audio controller


Earlier I talked about this project that I made with Patrick Brouwer. After all the positive response we got, we decided to make it available for everyone.

We wanted to make (multiplayer) flash games which could be controlled by your own voice. We first thought this would be very simple, since flash CS3 allows1 you to do a fft2 analysis on audio sources. However, this computeSpectrum3 function does not work on the microphone input (what a shame!).

We have created an alternative approach for this (worldwide4) known problem. We made a MaxMSP patch that does the FFT analysis and sends a OSC package5 to flash (with the help of a small java application). MAX/MSP6 sends the Amplitude and the pitch of a stereo signal (left and right). So, now we could use the input of the microphone to make a two-player game. If you only have one input they will both send the same data. In fact you will only get four paramaters in flash, you can do whatever you want with it (be creative)!

How to get this running.


First you have to download the package thats available here.

If you’ve got the package, unzip it and use your console to start the FLOSC server;

java Gateway 7000 3000


When this java server is running you can launch the MAX/MSP file that is located in the “maxmsp/Applications/” folder. It’s available for both windows and mac. We also included the MAX/MSP source code so you can change the patch like James Howard Young did.

When you launch the MAX/MSP patch it should look like this:

Also make sure that in your Flash Settings you can always access your microphone. You can do this by editing your global security settings and ‘add a location’. Fill in a slash (/) here.

Then it’s all set to run the pong game! You can find it in the swfs folder!


Please let me know if you have any trouble running it, or if you have created something with it.

The steps summarized:

We released this project under the Creative Commons Attribution-Noncommercial-Share Alike 3.0 Netherlands License, so please Share alike!



Flash Sound Controler by www.base42.nl is licensed under a Creative Commons Attribution-Noncommercial-Share Alike 3.0 Netherlands License.



1 Grant Skinner: Music Visualization Demos with computeSpectrum

2 Fast Fourier Transform

3 ComputeSpectrum reference

4 joshbuhler.com

5 FLOSC is the flash implimentation for OSC

6 Site to download MAX/MSP (not for free)

18.04.08
jankees van woezik
Comments

Timo about 2 hours later
How do I get the FLOSC server running? I'm typing java Gateway 7000 3000 in my terminal and I'm getting the following error: "Exception in thread "main" java.lang.NoClassDefFoundError: Gateway"
Jankees about 3 hours later
Are you in the right folder (flosc)?
Timo 3 days later
Thanks! I launched the max/msp patch, and it looks allright. But the pong game doesn't react to any sound..
James Young 10 days later
Try manually mousing numbers up and down in the number boxes (the four lowest in the max patch) and see if you get a result in the game.
Craig 2 months later
This is fantastic! I'm curious if you think this could ever be utilized to receive audio input from a users cell-phone and then control display in flash? Any insights on this question would be very helpful. Thanks much!
James Young 4 months later
For routing cell phone, you could probably just run a minijack from phone to computer and do it like that, provided the phone had such an option. I'm not sure how else you would get the phone to interface with the computer. If you wanted to have people play the game "long distance" then you could "just" have them send the parameters over network instead. Failing that, you could use Skype and then route your system audio through a bus (like Soundflower) into the Max patch.
Post a comment


Name
E-mail
Website
Comment
 
I am human (check to post)