xxxxxxxxxx
//0920_variable_face_project
//chin
float xc=237;
float yc=489;
float zc=398;
float wc =418;
//rface
float xf=360;
float yf=542;
float zf=481;
float wf=510;
float wyf=260;
//lface
float xlf=226;
float ylf=184;
float zlf=145;
float wlf=480;
float wxlf=100;
//hatshape
float xh=280;
float yh=207;
float zh=74;
float zyh=520;
float wh=565;
float wyh=340;
//lip
float lipx=0;
float lipy=0;
float lipz=0;
//nose
float np=0;
float npp=0;
//freck
//eyebrow
float eb=0;
//hat
float r=93;
float g=140;
float b=255;
//eyeball
float ex;
float ey;
void setup() {
size(620, 620);
background(0);
smooth();
colorMode(RGB);
}
void draw() {
background(0);
strokeWeight(3);
stroke(255);
noFill();
//leftear
beginShape();
curveVertex(243, 520);
curveVertex(150, 382);
curveVertex(115, 390);
curveVertex(118, 490);
curveVertex(19, 672);
endShape();
beginShape();
curveVertex(95, 183);
curveVertex(164, 438);
curveVertex(140+npp, 520);
curveVertex(118, 490);
curveVertex(213, 289);
endShape();
//rightear
bezier(506, 329, 562, 311, 537, 408, 504, 353);
stroke(#C085F5);
strokeWeight(6);
bezier(520, 354, 631, 270, 473, 476, 511, 369);
//face
//left cheeck
strokeWeight(3);
stroke(255);
beginShape();
curveVertex(251, 424);
curveVertex(xlf, 475);
curveVertex(ylf, wlf);
curveVertex(zlf, 306);
curveVertex(212, wxlf);
endShape();
//chin
beginShape();
curveVertex(221-237+xc, 336-389+zc);
curveVertex(xc, yc);
curveVertex(270-237+xc, 563-489+yc);
curveVertex(316, 554);
curveVertex(zc, wc);
endShape();
//right cheeck
beginShape();
curveVertex(162, 364);
curveVertex(xf, yf);
curveVertex(zf, 471);
curveVertex(wf, wyf);
curveVertex(550, 120);
endShape();
//left hat
strokeWeight(5);
stroke(r, g, b);
beginShape();
curveVertex(385, 590);
curveVertex(76, 311);
curveVertex(132, 78);
curveVertex(254, 15);
curveVertex(323, 22);
endShape();
//middledown hat
beginShape();
curveVertex(wh, wyh);
curveVertex(533, 245);
curveVertex(338, yh);
curveVertex(156, xh);
curveVertex(zh, zyh);
endShape();
beginShape();
curveVertex(37+zh-74, 460+zyh-520);
curveVertex(151, 239+xh-280);
curveVertex(328, 154+yh-207);
curveVertex(528, 200);
curveVertex(732+wh-565, 231+wyh-340);
endShape();
//middleleftdown hat
beginShape();
curveVertex(73, 240);
curveVertex(78, 314);
curveVertex(104, 346);
curveVertex(147, 284);
curveVertex(208, 363);
endShape();
//middledown right
beginShape();
curveVertex(265, 76);
curveVertex(533, 245);
curveVertex(556, 185);
curveVertex(362, 52);
curveVertex(-290, 12);
endShape();
strokeWeight(3);
//blushandfreckles
//left blush
beginShape();
curveVertex(322, 290);
curveVertex(298, 422);
curveVertex(254, 469);
curveVertex(229, 430);
curveVertex(176, 234);
endShape();
//right blush
beginShape();
curveVertex(480, 297);
curveVertex(466, 408);
curveVertex(435, 465);
curveVertex(414, 401);
curveVertex(412, 241);
endShape();
//left freck
strokeWeight(5);
point(273, 436+lipy);
point(241+lipx, 447);
point(243, 429+lipx);
point(261, 452-lipy);
point(261+lipy, 425);
point(282+lipx, 427+lipx);
point(253-lipy, 439);
//right freck
point(438+lipx, 450);
point(427+lipy, 441);
point(429, 414+lipx);
point(437-lipx, 427);
point(449+lipy, 435);
point(451, 421+lipy);
//lip
//lip bottom
stroke(#FA7777);
strokeWeight(3);
beginShape();
curveVertex(443, 379);
curveVertex(389, 489);
curveVertex(315, 534+lipx);
curveVertex(269, 499);
curveVertex(133, 343);
endShape();
//lip middle
beginShape();
curveVertex(443, 379);
curveVertex(370, 480);
curveVertex(315, 507);
curveVertex(289, 490);
curveVertex(268, 466);
endShape();
//lip up
beginShape();
curveVertex(500+lipz, 610);
curveVertex(387, 473+lipx);
curveVertex(343+lipz, 479+lipy);
//curveVertex(337, 480);
curveVertex(329+lipy, 483);
curveVertex(293+lipx, 475+lipz);
curveVertex(190, 610+lipy);
endShape();
//neck
stroke(255);
bezier(322, 556, 344, 570, 337, 582, 334, 595);
bezier(358, 549, 374, 570, 367, 582, 364, 595);
//nose
bezier(310, 287, 318, 367, 319, 367, 335+np, 380+npp);
line(335+np, 380+npp, 350, 368);
bezier(370, 380, 362, 368, 362, 368, 351, 365);
//nose bottom
bezier(391, 380, 354, 412+npp, 354, 412+npp, 329, 438);
//right eyebrow
strokeWeight(5+lipy);
bezier(431, 241, 431, 241, 399, 254, 368, 283);
//left eyebrow
bezier(255, 247+eb, 259, 247+eb, 259, 247+eb, 312, 263);
strokeWeight(8+lipx);
bezier(256, 248+eb, 256, 248+eb, 240, 269, 191, 313);
//eye
//left eye down
strokeWeight(3);
stroke(255);
bezier(288, 331, 288, 331, 239, 450, 202, 351);
//left eye bottom
bezier(232, 410, 214, 424, 214, 424, 190, 388);
//right eye bottom
bezier(477, 375, 447, 402, 447, 404, 420, 375);
//right eye up
bezier(258, 299, 231, 325, 231, 325, 195, 347);
bezier(259, 304, 275, 310, 275, 310, 289, 326);
//righteye
bezier(436, 264, 436, 286, 420, 320, 391, 325);
beginShape();
curveVertex(130, 564);
curveVertex(436, 264);
curveVertex(484, 334);
curveVertex(399, 320);
curveVertex(370, -85);
endShape();
//eyelashleft
line(258, 380, 274, 400);
line(243, 390, 250, 410);
line(200, 340, 182, 328);
line(202, 338, 202, 323);
line(218, 382, 206, 392);
//eyelashright
line(464, 350, 473, 365);
line(455, 356, 462, 374);
line(472, 345, 485, 359);
line(488, 257, 479, 267);
line(494, 268, 484, 277);
//eyeball
strokeWeight(11);
//point(455, 315);
point(ex, ey);
strokeWeight(5);
fill(255);
beginShape();
curveVertex(250, 791);
curveVertex(240, 358);
curveVertex(260, 346);
curveVertex(242, 358);
curveVertex(200, 86);
endShape();
ex=map(mouseX, 0, width, 435, 475);
ey=map(mouseY, 0, height, 295, 335);
//earring
noStroke();
fill(255, 0, 0);
ellipse(150, 417, 25+lipz, 30+lipz);
fill(255);
textSize(20);
text("m", 141, 422);
rectMode(CENTER);
stroke(#888789);
rect(137, 495, 16, 16);
fill(0);
rect(137, 495, 14, 14);
//fafafish
strokeWeight(1.5);
noFill();
stroke(#FFDE6F);
ellipse(264, 70, 55, 55);
ellipse(266, 74, 56, 55);
ellipse(268, 70, 57, 56);
ellipse(262, 72, 55, 57);
ellipse(262, 68, 57, 55);
//petal
noFill();
strokeWeight(3.5);
stroke(255);
bezier(259, 50, 356, -186, 399, 124, 285, 62);
bezier(239, 52, 126, -102, 299, -27, 262, 45);
bezier(239, 52, 128, -38, 129, 106, 241, 70);
bezier(256, 83, 198, 254, 139, 106, 241, 70);
bezier(256, 83, 178, 236, 302, 177, 273, 94);
bezier(291, 81, 428, 203, 284, 193, 273, 94);
bezier(291, 81, 490, 154, 366, -7, 285, 62);
//fish
strokeWeight(3.8);
point(307, 57);
strokeWeight(1.3);
strokeCap(ROUND);
stroke(#FF6464);
bezier(316, 59, 309, 73, 298, 61, 298, 61);
}
void mousePressed() {
xc=random(235, 240);
yc=random(485, 490);
zc=random(248, 407);
wc=random(305, 500);
r=random(82, 130);
g=random(82, 245);
b=random(235, 255);
xf=random(359, 361);
yf=random(541, 543);
zf=random(475, 495);
wyf=random(250, 270);
wf=random(507, 527);
xlf=random(224, 228);
ylf=random(184, 189);
zlf=random(145, 160);
wlf=random(475, 485);
wxlf=random(0, 500);
xh=random(278, 283);
yh=random(189, 215);
zh=random(30, 94);
zyh=random(450, 630);
wh=random(450, 620);
wyh=random(280, 420);
lipx=random(-2, 2);
lipy=random(-2, 2);
lipz=random(-2, 5);
np=random(-20, 1);
npp=random(3, 15);
eb=random(1, 13);
}