sketchpad's open studio is a place to create and share Processing canvases. Sign in now or sign up (free). X
 
 

Loading audio player from Soundcloud...
Embed this narration into the sketch's timeline

 
First sketch

Saved Sept 19, 2013
 
 
 
/*
Sketchcast demo
* Pause playback at any point to open an editable copy of that revision (link at upper-right)
* Navigate through the history of this sketch either with the revision slider or with the soundcloud audio slider. 
* Record your own sketchcast from the link in the header of any sketchpad that you're creating. 
*/
 
int i = 0; 
 
void setup() {  // this is run once, initially.
 
    // canvas size
    size(400,200);
 
    // background color (0 is black, 255 is white)
    background(255); 
    
    // line width 
    strokeWeight(12);
 
    // frames per second
    frameRate(15); 
}
 
void draw() { // this is run repeatedly
    
    // line color
    stroke(random(50), random(255), random(255), 100);
 
    // draw the line
    line(i,0, random(0,width), height);
 
    // loop when finished.
    if (i<width) { 
        i++;
    } else {
        i=0;
    }
}
 

Unless specified otherwise in the source code, this work, created by
Ari Bader-Natal
is licensed under a Creative Commons Attribution-Share Alike 3.0 License.

Creative Commons License

Authors

Ari Bader-Natal

Edit latest version


List all mods (87)

Export latest version

Source code
HTML (w/canvas)