Flash + JavaScript = Boo-o'meter
There has been a lot of talk recently about the future of Flash, and whether it is even going to be around for much longer. The consensus is certainly that the way Flash is used is changing, with JavaScript taking a more prominent role in providing animations and effects in a more accessible way, without the requirement of an extra plugin.
We’ve taken a fresh look at some of the things that only Flash can do, which still is quite varied in comparison to the new wave of HTML5 & CSS3 and this is one of our experiments. Typically a carousel either transitions automatically (on a timed basis), or by input from the mouse.
Using input from a user’s microphone we can provide a different experience by having loud noises (claps for example) trigger a transition (in addition to the automated time based method). This provides a more interesting spin and allows us to retain accessible content whilst introducing a fun, more interactive experience.
We’ve made use of the excellent jQuery Cycle plugin by Mike Alsup (malsup) and have also reworked Paul Neave’s NeaveLight class. There are lots of interesting Flash experiments on his website which is well worth checking out.
We have reworked the NeaveLight class so that instead of triggering sound to light effects, it uses Flash’s ExternalInterface command to send the microphone activity level to a JavaScript function in the HTML page.
The level of noise being picked up by your microphone is registered on the bar to the right of the carousel; try clapping or whistling to trigger the transition.
This could be turned into a children’s game on-site e.g. scaring away monsters by screaming at them, a ‘boo-o’meter for a music video etc. It could also degrade to using clicks when a microphone isn’t available etc.