xxxxxxxxxx
34
let capture;
let canvas1;
function setup() {
canvas1=createCanvas(480, 480);
capture = createCapture(VIDEO);
capture.hide();
}
function draw() {
push();
image(capture, 0, 0, width, width * capture.height / capture.width);
pop();
fill(255);
textSize(14);
textAlign(CENTER);
text('your skin color',mouseX,mouseY);
let color=get(mouseX,mouseY);
//console.log(color);
fill(color);
ellipse(width/2,3*height/4,80);
ellipse(width/4,3*height/4,80);
ellipse(3*width/4,3*height/4,80);
//textPosition=textPosition-1;
textSize(30);
text('always fascinated me', width/2,height-10);
}