Created
May 17, 2019 00:46
-
-
Save mrmemmo/8fee20c98f835822482a4291da008261 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| var mic, fft; | |
| function setup() { | |
| createCanvas(450,400); | |
| mic = new p5.AudioIn(); | |
| mic.start(); | |
| fft = new p5.FFT(); | |
| fft.setInput(mic); | |
| } | |
| function draw() { | |
| background(220); | |
| var spectrum = fft.analyze(); | |
| for (i = 0; i<130; i++) { | |
| //draw a shape here | |
| } | |
| } |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment