Music and Loops- A dance with death

The song I used for this is called Fiend, from a game called Shin Megami Tensei 4. This song is a macabre battle with the grim reaper himself, a sign of death and the end of life itself.  The beat is so intense, the pacing is exquisite, and so I desired to build around such a song. Utilizing the sense of euphoria one can get from witnessing flashing colors and various movements combine with the song to produce what I can only describe as a clash/battle in processing. 


My code:

import ddf.minim.*;
import ddf.minim.analysis.*;
Minim minim;
BeatDetect beat;
AudioPlayer song;
FFT fft;
float eRadius;
void setup()
size(614, 300);
minim = new Minim(this);
song = minim.loadFile(“Shin Megami Tensei IV OST – Battle C4 – (Fiend Battle Theme).mp3”, 512);;
fft = new FFT(song.bufferSize(), song.sampleRate());

//Beat to the music
beat = new BeatDetect();
eRadius = 20;

void draw()

stroke(random(200), 0, random(50), 40);
for(int x = 0; x < song.left.size() – 1; x++)
rect(x, 10 + song.left.get(x)*50, x+1, 10 + song.left.get(x+1)*25);
rect(x, 280 + song.left.get(x)*50, x+1, 10 + song.left.get(x+1)*25);
triangle(x, 100 + song.right.get(x)*50, x+4, 150 + song.right.get(x+1)*100, x, x*4);

for(int i = 0; i < fft.specSize(); i++)
ellipse(i++, height, i+ song.right.get(i)*100, height – fft.getBand(i)*4);
ellipse(i++, CENTER, i+ song.right.get(i)*100, height – fft.getBand(i)*4);
rect(i++,i+ song.right.get(i)*50, height – fft.getBand(i)*4, 10);


//circle booping to music
float a = map(eRadius, 100, 150, 60, 255);
fill(random(60), 255, random(150), a);
if ( beat.isOnset() ) eRadius = 80;
ellipse(550, height/2, eRadius/2, eRadius*1.5);
eRadius *= 0.25; beat.detect(song.mix);

fill(random(60), 255, random(150), a);
if ( beat.isOnset() ) eRadius = 80;
ellipse(550, height/2, eRadius*2, eRadius*1.5);
eRadius *= 0.25;

fill(random(60), 255, random(150), a);
if ( beat.isOnset() ) eRadius = 100;
ellipse(550, height/4, eRadius*2, eRadius*1.5);
eRadius *= 0.75;

//moving shapes with mouse




About Alex Mandzi

I'm a new artist and wish to become a game designer. I like cartoons and draw them as well.
This entry was posted in Computer Animation, Time-Based and tagged , , , . Bookmark the permalink.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s