Last active
August 29, 2015 13:58
-
-
Save runemadsen/10077991 to your computer and use it in GitHub Desktop.
This file contains 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
void setup() | |
{ | |
size(1000, 800); | |
translate(0, height/2); | |
float x = 0; | |
while(x < width) | |
{ | |
float y = sin(x/50.0) * 50; | |
ellipse(x, y, 10, 10); | |
x += 30; | |
} | |
} | |
void setup() | |
{ | |
size(1000, 800); | |
translate(0, height/2); | |
float x = 0; | |
beginShape(); | |
while(x < width) | |
{ | |
float y = sin(x/50.0) * 50; | |
vertex(x, y); | |
x += 30; | |
} | |
vertex(width, height); | |
vertex(0, height); | |
endShape(CLOSE); | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment