Monthly Archives: August 2010

Vectors vs. Linked Lists in AS3


One of the new features in Flash Player 10 was the Vector class, essentially a typed Array. For many operations it gives a substantial performance boost compared to Array. See Mike Chambers blog posts for an introduction on using Vectors and for Vector/Array Performance Comparison. While Vector is definitely faster than Array, if you mainly need to access values in sequence you can actually get better performance using linked lists. Continue reading

Posted in Audio, Flash, Programming | 5 Comments

Real-Time Spectrum Analysis


One of the new features in Flash Player 10.1 is real-time access to microphone audio input data. Using that feature and my AS3 FFT I created a real-time audio spectrum analyzer. Here’s a screenshot of its output: Here I’m singing … Continue reading

Posted in Audio, Flash, Programming | 89 Comments

Code for FFT Timing Test


Further to my last two posts on FFTs in AS3, here’s the code I used to measure the speed. On my 2006 MacBook Pro (2GHz Core Duo), with a release build of the swf, this runs in ~660 ms using … Continue reading

Posted in Audio, Flash, Programming | Tagged | 6 Comments

An even faster AS3 FFT


Earlier today I posted code for a fairly fast pure-AS3 FFT implementation. Andre Michelle suggested that I could perhaps get better performance by using linked lists instead of Vectors.  He was right!  I have a new FFT implementation that runs … Continue reading

Posted in Programming | Tagged , | 60 Comments

An FFT in AS3


I write a lot of audio signal processing code, a fair bit of which works in the frequency domain. A key building block for almost any frequency domain signal processing is the FFT, an efficient implementation of the DFT. A … Continue reading

Posted in Audio, Flash, Programming | Tagged , | 18 Comments