ljkim project 07

sketch

function setup() {
    createCanvas(480, 480);
    frameRate(10);
}

function draw() {
    background("#9CE2F7");
    fill(255, 255, 255, 64);
    translate(width/2, height/2); //moves lines to center of the canvas

    
    // draw the circle as a starburst
    push();
    for (var i = 0; i < 20 ; i++) {
        var theta = map(i, 0, 20, 0, TWO_PI);
        var px = 50 * cos(theta);
        var py = 50 * sin(theta);
        line(0, 0, px, py);
    }
    pop();
}

Leave a Reply