import processing.sound.*;
SoundFile s;
Amplitude amp;
float a,b,c;
void setup()
{
size(800,800);
background(0);
s= new SoundFile(this,”westworld.mp3″);
amp= new Amplitude(this);
amp.input(s);
s.play();
}
void draw()
{
c=amp.analyze()*600;
translate(400,400);
rotate(radians(a=a+c));
rectMode(CENTER);
stroke(random(255),0,random(255));
strokeWeight(3);
noFill();
ellipse(0,0,c*2,c);
}
Leave a Reply
You must be logged in to post a comment.