Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- void setup() {
- size(650, 650);
- background(255);
- }
- void draw() {
- stroke(random(50, 100), random(100, 200), random(50, 100), 80);
- line(calc(1000, width), calc(1100, height), calc(1200, random(200, 400)*0.2), calc(1300, random(200, 400)*0.9));
- }
- float calc(float a, float b) {
- return abs(sin(millis()/a)*b);
- }
- void keyPressed() {
- if (key == 's') saveFrame("image-###.png");
- }
Advertisement
Add Comment
Please, Sign In to add comment