"Sageata" - Processing

ID Autor Duplicat din Ultima modificare
#1 Candale Silviu (silviu) - Duminica, 12 iun 2016, 22:34
x
 
1
function setup() {
2
    createCanvas(400, 400);
3
    frameRate(1);
4
    noLoop();
5
}
6
7
function draw() {
8
    fill(200,0,0);
9
  
10
    beginShape();
11
    vertex(50, 100);
12
    vertex(250, 100);
13
    vertex(250,  50);
14
    vertex(350, 150);
15
    vertex(250, 250);
16
    vertex(250, 200);
17
    vertex(50, 200);
18
    endShape();
19
  
20
    if(frameCount % 2 != 0)
21
        fill("yellow");
22
    else
23
        fill("gray");
24
    textSize(30);
25
    textStyle(BOLD);
26
    text("Processing JS", 80,160);
27
}
28
Du-te sus!