Code

size(400,400);
background(0);


noStroke();
beginShape(QUAD_STRIP);
fill(255,255,0);
vertex(100,100);
vertex(100,135);
vertex(125,135);
vertex(125,100);
fill(218,165,32);
vertex(160,100);
vertex(160,160);
vertex(195,160);
fill(255,69,0);
vertex(195,100);
endShape();

stroke(255);
beginShape(TRIANGLE_STRIP);
fill(132,112,255);
vertex(200,200);
vertex(220,240);
fill(135,206,250);
vertex(240,200);
fill(255,255,224);
vertex(280,240);
fill(255,222,173);
vertex(300,200);
endShape();

noStroke();
beginShape(POLYGON);
fill(255,91,71);
vertex(100,300);
vertex(115,322);
vertex(190,315);
vertex(140,173);
endShape();

011 -- Basic Primitives: Graphics Primitives using BeginShape/EndShape

Statement:Create a simple static composition which demonstrates your ability to render the following graphics primitives: TRIANGLE_STRIP, QUAD_STRIP, POLYGON. The composition should be 400x400 pixels, and you should use color judiciously. Experiment with independently-colored vertices [using the fill() command], and designs that use stroke() versus nostroke().

hide statement