I'm building a site that requires an audio file to be played with an equalizer. I don't know alot about AS3 yet so this might be a simple question.
I've found an example that I would like to use Demonstrated here and the source files here
The code to add the equalizer object to the stage (from the tutorial)
package {
import flash.media.*;
import flash.net.*;
import flash.display.*;
import flash.events.*;
import com.everydayflash.equalizer.*;
import com.everydayflash.equalizer.color.*;
public class Main extends Sprite{
public function Main() {
var s:Sound = new Sound(new URLRequest("track.mp3"));
s.play(0, 100, new SoundTransform(1, 0));
var es:EqualizerSettings = new EqualizerSettings();
es.numOfBars = 32;
es.height = 64;
es.barSize = 2;
es.vgrid = true;
es.hgrid = 2;
es.colorManager = new SolidBarColor(0xffff4444);
es.effect = EqualizerSettings.FX_REFLECTION;
var e:Equalizer = new Equalizer();
e.update(es);
e.x = 100;
e.y = 100;
addChild(e);
addEventListener(Event.ENTER_FRAME, e.render);
}
}
}
This creates a vertically oriented equalizer with some pretty nice effects.
However I would like it to be horizontal so I believe I need to rotate "e" 90 degrees. Do any of you know how to do this? Or is the orientation dictated exclusively by the action script that creates it?
Thanks for any help you have.