This is a late post but late is better than nothing. My very first piece of work ever in processing is an “equalizer” for an mp3 file. It’s pretty much basic (well, lame even under my standard) but featuring the FFT and BeatDetect interface in minim library.
I played around with the functions the FFT provides and decided to use both the Forward Transform to create full spectrum of the piece of music, and the Averages to see what it would be different than the full scale. I put them oppose from bottom and the top of the screen so that I could compare the amplitutes of different frequences and the aggregated/average values while groups of frequences are combined.
As can be seen from the screenshot the “average” group has fewer bands. However the shape doesn’t look right compared to the full spectrum, although the most loud parts of the sound gather around lower frequencies, the average shows the most heavy part in the middle. This is because the average was initiated and calculated as Log-Average in stead of Linear. To use a linear average just change the initializing statement from:
fftLog.logAverages(22, 3);
to:
fftLog.linAverages(30);
It turned out to be what’s expected. Still not making much sense though.
Another important factor I thought was important for music visualization is the beat. So I made splash-like effect to the canvas whenever a beat was detected. This is pretty straight-forward and not doing well with the sample music. The sound energy mode tracks just “significant spikes in the level” so it might not be accurate for all samples.
TO-DOs for week2
* Make visualization more comprehensive;
* Add dimension of time;
* Allow interaction for exploration into the music
* Try Frequency Energy mode for beat detecting, which is much for flexible with custom parameters in isRange() functionality;
applet link here: http://leejayxia.com/processing/v5s_week1/



Post a Comment