Jonathan Liang – Project 02 – Variable Face

sketch

// Simple beginning template for variable face.
var eyeSize = 30;
var eyeHeight = 2.5 * eyeSize;
var eyeWidth = 2 * eyeSize;
var faceWidth = 300;
var faceHeight = 300;
var canvasWidth = 640;
var canvasHeight = 480;
var pupilWidth = 10;
var pupilHeight = 15;
var mouthStroke = 3;
var llWall = canvasWidth / 2 - eyeSize - pupilWidth;
var lrWall = canvasWidth / 2 - eyeSize + pupilWidth;
var rlWall = canvasWidth / 2 + eyeSize - pupilWidth;
var rrWall = canvasWidth / 2 + eyeSize + pupilWidth;
var tlWall = canvasHeight / 2 - eyeSize * 3 - eyeSize;
var blWall = canvasHeight / 2 - eyeSize * 3 + eyeSize;
var trWall = canvasHeight / 2 - eyeSize * 3 - eyeSize;
var brlWall = canvasHeight / 2 - eyeSize * 3 +  eyeSize;
var mouthStart = 320;
var noseSize = eyeSize
var backgroundColor = 1;
var headColor = 1;




function setup() {
    createCanvas(640, 480);
}

function draw() {
    switch(backgroundColor){
    	case 1:
    		background('pink');
    		break;
    	case 2:
    		background('lime');
    		break;
    	case 3:
    		background(71, 170, 215);
    		break;
    	case 4:
    		background('magenta');
    		break;
    	case 5:
    		background('cyan');
    		break;
    	case 6:
    		background('orange')
    		break;
    	case 7:
    		background(237,204, 248);
    		break;
    	case 8:
    		background('yellow');
    		break;
    	}

//head
    noStroke();
    switch(headColor){
    	case 1:
    		fill(71, 170, 215);
    		break;
    	case 2:
    		fill('yellow');
    		break;
    	case 3:
    		fill('lime');
    		break;
    	case 4:
    		fill('red');
    		break;
    	case 5:
    		fill('orange');
    		break;

    }
    strokeWeight(3);
    ellipse(canvasWidth / 2, canvasHeight / 2, faceWidth, faceHeight);
    

//white fills on face 
    noStroke();
    fill('white');
    ellipse(canvasWidth / 2, canvasHeight / 2 + eyeSize, faceWidth/1.25, faceHeight/1.25);

//eyes
    ellipse(canvasWidth / 2 - eyeSize, canvasHeight / 2 - eyeSize * 3, 2 * eyeSize, 2.5 * eyeSize);
    ellipse(canvasWidth / 2 + eyeSize, canvasHeight / 2 - eyeSize * 3, 2 * eyeSize, 2.5 * eyeSize);

//pupils
	var xrL = constrain(mouseX, llWall, lrWall);
	var xrR = constrain(mouseX, rlWall, rrWall);
	var yrL = constrain(mouseY, tlWall, blWall);
	var yrR = constrain(mouseY, trWall, brlWall);

    noStroke();
    fill('black');
    ellipse(xrL, yrL, pupilWidth, pupilHeight);
    ellipse(xrR, yrR, pupilWidth, pupilHeight);


//mouth
	noFill();
	stroke('black');
	strokeWeight(mouthStroke);
	line(canvasWidth / 2, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight, canvasWidth / 2, mouthStart);
	arc(canvasWidth / 2, mouthStart - faceWidth / 4, faceWidth * 0.65, faceWidth * 0.5, 0, PI, OPEN);

	
//left whiskers	
	line(canvasWidth / 2 - 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6, canvasWidth / 2 - noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight);
	line(canvasWidth / 2 - 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 2, canvasWidth / 2 - noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 2);
	line(canvasWidth / 2 - 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 4, canvasWidth / 2 - noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 3);
	
//right whiskers
	line(canvasWidth / 2 + noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight, canvasWidth / 2 + 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6);
	line(canvasWidth / 2 + 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 2, canvasWidth / 2 + noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 2);
	line(canvasWidth / 2 + 1.75 * eyeWidth, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 4, canvasWidth / 2 + noseSize, canvasHeight / 2 - eyeSize * 1.6 + pupilHeight * 3);
	
//nose and highlight
    noStroke();
    fill('red');
    ellipse(canvasWidth / 2, canvasHeight / 2 - eyeSize * 1.6, noseSize, noseSize);

    noStroke();
    fill('white');
    ellipse(canvasWidth / 2 - 1, canvasHeight / 2 - eyeSize * 1.63, pupilWidth, pupilWidth);    
    
}

function mousePressed() {
    // when the user clicks, these variables are reassigned
    // to random values within specified ranges. For example,
    // 'faceWidth' gets a random value between 75 and 150.
    faceWidth = random(10, 250);
    faceHeight = random(150, 250);
    eyeSize = random(10, 40);
    noseSize = random(10, 70);
    backgroundColor = int(random(1,8));
    headColor = int(random(1,5));
   

}

As a child, one of my favorite cartoons was Doraemon. I always wondered if there were more to the Doraemon family and if they were in different colors. I also took inspiration from a scene in Guardians of the Galaxy volume 2, I’m not gonna specify which scene.

Jonathan Liang – Looking Outwards-02

digital DADA

DATA-DADA is a series of algorithms created by Holger Lippmann that reads different color map arrays and represents them in circles and lines. DATA-DADA has created three series of maps. I found these maps interesting because in my architecture studio right now we are studying mapping and these maps can serve as inspiration for me and my projects. One thing that could be more better about these series of projects is if they could specify what the data is about or what they are representing.  But I do love the ambiguity that these circles and lines create. I do not specifically know what inspired Mr. Lippmann, but his DADA series reminds me a lot of Takeshi Murakami’s superflat style. Both artists have a very similar aesthetic, even though Lippmann utilizes data rather than made-up characters.

http://www.lumicon.de/wp/?p=3397

 

 

 

Jonathan Liang – Project 1 – Face

sketch

/*Jonathan Liang
Section A
jliang2@andrew.cmu.edu
project_01*/



function setup() {
    createCanvas(600, 600);
    background(22, 13, 16);
    text("p5.js vers 0.7.1 test.", 10, 15);
}

function draw() {
	
//face
	fill(253, 240, 81);
	noStroke();
	ellipse(300, 330, 220, 200);

	fill(205, 82, 48);
	noStroke();
	arc(308, 390, 159, 80, 0, HALF_PI);

	fill(205, 82, 48);
	noStroke();
	quad(300, 330, 410, 330, 390, 400, 300, 365);

	fill(205, 82, 48);
	noStroke();
	triangle(300, 360, 310, 400, 389, 400);

	fill(22, 13, 16);
	noStroke();
	triangle(190, 330, 190, 430, 225, 430);

	fill(22, 13, 16);
	noStroke();
	triangle(410, 330, 410, 430, 375, 430);

	fill(205, 82, 48);
	noStroke();
	quad(300, 360, 290, 380, 310, 400, 387, 398);


//eyes
	fill('white');
	noStroke();
	ellipse(250, 330, 50, 40);

	fill('white');
	noStroke();
	ellipse(350, 330, 50, 40);

//shades
	fill(22, 13, 16);
	noStroke();
	arc(250, 330, 68, 60, 0, PI + QUARTER_PI, CHORD);

	fill(22, 13, 16);
	noStroke();
	arc(350, 330, 68, 60, 0, PI + QUARTER_PI, CHORD);

	noFill();
	stroke(22, 13, 16);
	strokeWeight(15);
	curve(250, 325, 283, 330, 317, 330, 350, 325)

//buckethat
	fill(253, 240, 81);
	noStroke();
	quad(180, 180, 420, 170, 440, 330, 160, 330);
	
	fill(253, 240, 81);
	triangle(170, 315, 170, 330, 130, 330);
	noStroke();

	fill(205, 82, 48);
	triangle(430, 320, 430, 330, 450, 330);
	noStroke();

	fill(205, 82, 48);
	noStroke();
	quad(200, 200, 420, 170, 440, 330, 190, 330);

//design
	noFill();
	stroke(253, 240, 81);
	strokeWeight(10);
	ellipse(300, 241, 110, 110);

	fill(253, 240, 81);
	noStroke();
	textSize(75);
	text('梁', 266, 265);


//text
	fill(205, 82, 48);
	noStroke();
	textSize(10);
	text('little man, big hat', 265, 500);
	

}

Jonathan Liang – Looking Outwards – 01

the future of transportation: printed one part at a time

While browsing through the futurefeeder blog, I came across a post about an artist who 3D printed an entire motorcycle. The artist recreated an entire Honda CB500 with just an Ultimaker 3D printer. Impressive, is it not? To me, not really. 3D printing vehicles has been a hot topic as of late and companies like Strati have already started prototyping 3D printed vehicles, that work. Of course none of Strati’s vehicles are entirely 3D printed, but the time soon will come when all parts and components to vehicles will be 3D printed. 3D printed vehicles come with many advantages, such as: lighter vehicle weight, reduced material loss, faster iteration process during the design process,  easier parts replacement, and anyone can customize their own cars. There will obviously be bumps along the process, but this seems like the clear future of the transportation industry.

New York artist creates a life-sized Honda CB500 motorcycle using just an Ultimaker 3D printer