aboyle-Looking Outwards-03

For this post, I have chosen to discuss a project known as “Digital Grotesque”, specifically Grotto II, which is the second and (in my opinion) more impressive creation. The architects behind this project are Michael Hansmeyer and Benjamin Dillenburger, who worked with a fabrication team of 6 people. Their website can be found at https://digital-grotesque.com/.

Grotto II premiered in March 2017. It is 3.45 meters high, is made out of 7 tons of printed sandstone, and contains a space where people can enter and marvel at the 1.35 billion surfaces. What I most admire about this project is the sheer scale. While I’ve become somewhat accustomed to small 3D printed trinkets, the idea of a complexly decorated room created through 3D printing is still novel to me. It’s also exciting to know that people are willing to devote years of their lives to in order to fully explore the field of 3D printing.

Above: Inside the Digital Grotesque grotto. Link: https://digital-grotesque.com/architecture/

Grotto II was designed entirely by algorithms. According to the website, “a subdivision algorithm exploits the 3D printer’s full potential by creating porous, multi-layered structures with spatial depth. A single volume spawns millions of branches, growing and folding into a complex topological structure.” The algorithms do not incorporate randomness, but the creators say that the results were not necessarily foreseeable. Although the artists say that they tried to avoid referencing any existing architectural styles, their interest in architecture as a whole is clearly evident in the work.

nayeonk1-Project03-Dynamic Drawing

nayeon_DynamicDrawing

//Na-yeon Kim
//15-104, B section
//nayeonk1@andrew.cmu.edu
//Project-03 (Dynamic Drawing)


var angle = 0;
var dia = 0;


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

function draw() {

//background color changing with mouse
    var bgR = map(mouseY, 0, height, 50, 100);
    var bgG = map(mouseX, 0, height, 150, 250);
    var bgB = map(mouseY, 0, height, 100, 200);

    background(bgR, bgG, bgB);

//size changing rect
    noStroke();
    fill(bgR + 100, bgG + 100, bgB + 100);
    rect(0, 0, (mouseX / 2), (mouseY / 2));
    fill(bgR - 100, bgG - 100, bgB - 100);
    rect(100, 100, (mouseX / 2), (mouseY / 2));
    fill(bgR - 50, bgG, bgB + 100);
    rect(200, 200, (mouseX / 2), (mouseY / 2));
    fill(bgR, bgG + 100, bgB + 200);
    rect(300, 300, (mouseX / 2), (mouseY / 2));


//another bg frame
    var x = 50;
    var y = 100;
    var w = 380;
    var h = 440;

    noStroke();
    if ((mouseX > x) & (mouseX < x+w) && (mouseY > y) && (mouseY < y+h)) {
      fill(0, 250);
    } else {
      fill(255, 0);
    }
    rect(x, y, w, h);

//rotating rect
    if ((mouseX > x) & (mouseX < x+w) && (mouseY > y) && (mouseY < y+h)) {
      fill(bgR, bgG, bgB);
    } else {
      fill(255, 0);
    }
    push();
    translate((width / 2), (height / 2));
    rotate(radians(angle));
    rectMode(CENTER);
    rect(0, 0, (mouseX / 2), (mouseY / 2));
    pop();
    angle = angle + 20;

//lines
    var wL = 50;
    var wR = 430;
    var hU = 100;
    var hB = 540;

    var xc = constrain(mouseX, wL, wR);
    var yc = constrain(mouseY, hU, hB);

    if ((mouseX > x) & (mouseX < x+w) && (mouseY> y) && (mouseY < y+h)) {
      stroke(255);
    } else {
      stroke(0);
    }

    strokeWeight(8);
    line((width / 2), (height / 2), xc, yc);
    var max = map(mouseX, 0, xc, yc, 100);
    line((width/ 2), (height / 2), max, yc);
    var max = map((mouseX * 0.5), 0, xc, yc, 200);
    line((width/ 2), (height / 2), max, yc);
    var max = map((mouseX * 2), 0, xc, yc, 50);
    line((width/ 2), (height / 2), max, yc);

// cursur - spinning rect
    push();
    rectMode(CENTER);
    if ((mouseX > x) & (mouseX < x+w) && (mouseY> y) && (mouseY < y+h)) {
      fill(255);
    } else {
      fill(0);
    }
    noStroke();
    translate(mouseX, mouseY);
    rotate(radians(angle * 10));
    rect(0, 0, 30, 30);
    pop();

//increasing circle
    if ((mouseX > x) & (mouseX < x+w) && (mouseY > y) && (mouseY < y+h)) {
    } else {
      dia = 0;
    }
    push();
    noStroke();
    fill(255);
    ellipse((width / 2), (height / 2), dia, dia);
    dia = dia + 1;
    pop();

    fill(0);







}

I tried to implement codes I’ve learned this week. And I wanted to try something new, I started to design abstract image as much as possible only thinking about function. It was fun to do something different with I used to do it. It was fun to play with different codes!

heeseoc-project-03-DynamicDrawing

heeseoc-dynamic

//Steph Chun
//15-104 section #A
//heeseoc@andrew.cmu.edu
//Project-03

	var dir = 1;
	var speed = 4;
	var diam = 0;
	var dot = 3;
	var o = 1;
	var oo = 1;
	var angle = 0;
	var angleo = 0;


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

function draw() {
	noStroke(); 

	var center = 135;
	var c = constrain(mouseX, -150, center);


	//background//
	background (255-c*1.5,255-c*1.5,255-c*1.5);


	//hand right//
	fill (227,200,113);
	quad (-c+615,233,-c+681,299,-c+615,365,-c+549,299);

	fill (212,180,75);
	quad (-c+690,299,-c+640,249,-c+590,299,-c+640,349);

	fill (150,132,65);
	triangle (-c+610,299,-c+660,249,-c+660,349);

	fill (227,200,113);
	triangle (-c+614.5,233,-c+690,250,-c+680,299);

	fill (241,216,141);
	rect (-c+640,250,320,75);
	triangle (-c+640,250,-c+640,325,-c+600,250);
	rect (-c+490,250,130,30);
	triangle (-c+490,250,-c+490,280,-c+455,250);

	triangle (-c+725,325,-c+695,325,-c+695,355);
	rect (-c+590,325,105,30);
	triangle (-c+590,325,-c+590,355,-c+575,325);

	//fingernails right//
	fill (255,238,189);
	rect(-c+470,250,30,13);
	triangle (-c+470,250,-c+470,263,-c+455,250);


	//rotating dots//
	if (mouseX > 100) {
	push();
    translate(320,250);
    rotate(radians(angle));
    angle = angle + 10;
    fill(255);
    ellipse(-o, o, dot, dot);
    pop();
    o = o + 0.3;
	}

	if (mouseX > 80) {
	push();
    translate(320,250);
    rotate(radians(angleo));
    angleo = angleo + 3;
    fill(255);
    ellipse(-oo, oo, dot, dot);
    pop();
    oo = oo + 0.1;
	}

	if (mouseX > 120) {
	push();
    translate(320,250);
    rotate(radians(-angleo));
    angleo = angleo + 3;
    fill(255);
    ellipse(-oo-50, oo+50, dot, dot);
    pop();
    oo = oo + 0.1;
	}

	if (mouseX < 80) {
		o = 0;
		oo = 0;
	}

	//ripples//
	stroke (255);
	noFill();
	ellipse (320,250,diam/3,diam);
	ellipse (320,250,diam/4.5,diam/1.5);

	diam += dir * speed;
    if (mouseX < 135) {
        diam = 0;
	}


	noStroke();

	//hand left//
	fill (167,157,203);
	quad (c+25,233,c+91,299,c+25,365,c-41,299);

	fill (141,129,183);
	quad (c+50,299,c,249,c-50,299,c,349);

	fill (115,107,141);
	triangle (c+30,299,c-20,249,c-20,349);

	fill (167,157,203);
	triangle (c+25.5,233,c-50,250,c-40,299);

	fill (186,178,217);
	rect (c-320,250,320,75);
	triangle (c,250,c,325,c+40,250);
	rect (c+20,250,130,30);
	triangle (c+150,250,c+150,280,c+185,250);

	triangle (c-85,325,c-55,325,c-55,355);
	rect (c-55,325,105,30);
	triangle (c+50,325,c+50,355,c+65,325);

	//fingernails left//
	fill (216,209,241);
	rect(c+140,250,30,13);
	triangle (c+170,250,c+170,263,c+185,250);

	
 }

My original idea was to make the touch convey a sense of affection between the two people, but I changed it later on so that with the interactions, it looks more like a reflection (yet the viewers may not know at their first sight which is the twist I intended to give to this piece). Getting one hand to exactly reflect the other hand was the most difficult part for me, because I calculated all the coordinating numbers since I didn’t know how to take a combination of objects and just flip it over.

dayoungl – Project03

sketch

// Sharon Lee
// Section E
// dayoungl@andrew.cmu.edu
// Project-03
var colour1 = 255;
var colour2 = 235;
var colour3 = 107;
var angle = 0;
var x = 350;
var y = 350;
var dirX = 1;
var dirY = 0.3;
var speed = 5;
var cirSize = 80;
var point1 = 650;
var point2 = 350;
var point3 = 50;
var front = 1;
var count = 0;

function setup() {
    createCanvas(640,480);
    angleMode(DEGREES);
}
function draw() {
    background(0);
    rectMode(CENTER); 
    //moon 1 in front of the planet
    if (front == 1){
        //planet
        fill(colour1,colour2,colour3);
        noStroke();
        ellipse(width/2 +50, height/2, 300,300);
        //moon1
        fill(colour1);
        noStroke();
        ellipse(x, height/2, cirSize, cirSize);
    }
    //moon 1 behind planet
    if (front == 0){
        //moon1
        fill(colour1);
        noStroke();
        ellipse(x, height/2, cirSize, cirSize);
        //planet
        fill(colour1,colour2,colour3);
        noStroke();
        ellipse(width/2 +50, height/2, 300,300);
    }
    //stars that follow mouseX and mouseY
    push();
    angle = angle + 50;
    translate(mouseX,mouseY);
    stroke(139,94,193);
    strokeWeight(10);
    rotate(angle);
    rectMode(CENTER);
    rect(0, 0, 40, 30);
    rotate(angle);
    rect(0, 0, 40, 30);
    rotate(angle);
    rect(0, 0, 40, 30);
    pop();

    //star2
    push();
    angle += 1;
    translate(mouseX -60, mouseY -60);
    stroke(73,50,102);
    strokeWeight(7);
    rotate(angle);
    rect(0,0,10,20);
    rotate(angle);
    rect(0,0,10,20);
    rotate(angle);
    rect(0,0,10,20);
    pop();

    //star3
    fill(73,111,102);
    noStroke();
    ellipse(mouseX, mouseY -100, 10,10);
    //star4
    ellipse(mouseX, mouseY,8,8);
    //star5
    ellipse(mouseX-80, mouseY-55, 15,15);
   
    //location of moon1
    if (x <= point1){  
        x += dirX * speed;
    }
    if (x <= point1 & x >= 350){
        cirSize -= 1;
    }
    if (x <= 350 & x >= point3){
        cirSize += 1;
    }
    if (x >= point1) {
        dirX = -dirX;
        front = 0;
    }
    if (cirSize <= 350 & x <= point3) {
        dirX = -dirX;
        front = 1;
        count += 1;
    }

    // planet changes color every revolution
    if (count % 10 == 1) {
        colour1 = 255;
        colour2 = 235;
        colour3 = 68;
    }
    if (count % 10 == 2) {
        colour1 = 255;
        colour2 = 215;
        colour3 = 68;

    }
    if (count % 10 == 3) {
        colour1 = 255;
        colour2 = 195;
        colour3 = 68;
    } 
    if (count % 10 == 4) {
        colour1 = 255;
        colour2 = 180;
        colour3 = 68;
    }
    if (count % 10 == 5){
        colour1 = 255;
        colour2 = 165;
        colour3 = 68;
    }
    if (count % 10 == 6){
        colour1 = 255;
        colour2 = 150;
        colour3 = 68;
    }
    if (count % 10 == 7){
        colour1 = 255;
        colour2 = 135;
        colour3 = 68;
    }
    if (count % 10 == 8){
        colour1 = 255;
        colour2 = 120;
        colour3 = 68;
    }
    if (count % 10 == 9){
        colour1 = 255;
        colour2 = 105;
        colour3 = 68;
    }
}

Orbital system
I wanted to make an image of moon orbiting the planet along with with other visual decorations that move around as the mouse moves. I had difficulty making the moon go behind the planet every revolution but I eventually figured it out.

Hannahk2-Project03-DynamicDrawing

sketch

//Hannah Kim
//Section A
//hannahk2@andrew.cmu.edu
//Assignment-01

function setup() {
  createCanvas(600, 600);
}

function draw() {
  background(0, 0, 0);

//background color change
//as mouse moves down, color changes from blue 
//to lighter blue
    var Rc = map(mouseY, 0, height, 200, 260);
    var Gc = map(mouseY, 0, height, 240, 255);
    var Bc = map(mouseY, 0, height, 250, 255);

    noStroke();
    fill(Rc, Gc, Bc);
    rect(0, 0, 600, 600);

//circle background color change
//as mouse moves down, color changes from white
//to blue
    var circSize =map(mouseY, 0, height, 0, 400);
    var Rc1 = map(mouseY, 0, height, 260, 200);
    var Gc1 = map(mouseY, 0, height, 255, 240);
    var Bc1 = map(mouseY, 0, height, 255, 250);
noStroke();
fill(Rc1, Gc1, Bc1);
ellipseMode(CENTER);
ellipse(294, 242, circSize, circSize);

//top chopstick
var topChop = map(mouseY, 0, 400, 92, 300);
stroke(198, 58, 61);
strokeWeight(9);
line(27, 60, 291, topChop);

//noodle 1
var nood1 = map(mouseY, 0, 400, 76, 310);
stroke(221, 215, 153);
strokeWeight(6);
line(240, nood1, 240, 311);

//noodle2
var nood2 = map(mouseY, 0, 400, 76, 312);
stroke(221, 215, 153);
strokeWeight(6);
line(252, nood1, 253, 313);

//noodle3
var nood3 = map(mouseY, 0, 400, 76, 312);
stroke(221, 215, 153);
strokeWeight(6);
line(266, nood3, 266, 316);

//bottom chopstick
var bottomChop = map(mouseY, 0, 400, 107, 310);
stroke(198, 58, 61);
strokeWeight(9);
line(5, 111, 292, bottomChop);

noStroke();
//draw ramen cup
fill (233, 231, 226);
rect (164, 261, 272, 8);
quad (175, 275, 210, 560, 386, 561, 428, 277);
noStroke();
arc(297, 561, 176, 10, TWO_PI, PI);

//draw top row of yellow marks
fill(194, 198, 89);
rect(182, 300, 3, 24);
rect(188, 300, 3, 24);
rect(194, 300, 3, 24);
rect(200, 301, 3, 24);
rect(207, 301, 3, 24);
rect(214, 302, 3, 24);
rect(222, 302, 3, 24);
rect(230, 302, 3, 24);
rect(239, 303, 3, 24);
rect(248, 303, 3, 24);
rect(257, 303, 3, 24);
rect(267, 304, 3, 25);
rect(277, 304, 3, 25);
rect(287, 304, 3, 25);
rect(297, 304, 3, 25);
rect(307, 304, 3, 25);
rect(317, 303, 3, 25);
rect(326, 303, 3, 24);
rect(335, 303, 3, 24);
rect(344, 303, 3, 24);
rect(352, 303, 3, 24);
rect(361, 303, 3, 24);
rect(369, 303, 3, 24);
rect(377, 303, 3, 24);
rect(385, 302, 3, 24);
rect(392, 302, 3, 24);
rect(399, 301, 3, 24);
rect(405, 300, 3, 24);
rect(411, 300, 3, 24);
rect(417, 300, 3, 24);

//draw bottom row of yellow marks
fill(194, 198, 89);
rect(207, 501, 3, 24);
rect(214, 502, 3, 24);
rect(222, 502, 3, 24);
rect(230, 502, 3, 24);
rect(239, 503, 3, 24);
rect(248, 503, 3, 24);
rect(257, 503, 3, 24);
rect(267, 504, 3, 25);
rect(277, 504, 3, 25);
rect(287, 504, 3, 25);
rect(297, 504, 3, 25);
rect(307, 504, 3, 25);
rect(317, 503, 3, 25);
rect(326, 503, 3, 24);
rect(335, 503, 3, 24);
rect(344, 503, 3, 24);
rect(352, 503, 3, 24);
rect(361, 503, 3, 24);
rect(369, 503, 3, 24);
rect(377, 503, 3, 24);
rect(385, 502, 3, 24);

//draw red background for middle logo 
fill(198, 58, 61);
rect(272, 354, 79, 58);
arc(346, 374, 50, 40, PI+QUARTER_PI, HALF_PI);
ellipseMode(CENTER);
ellipse(263, 383, 59, 63);
quad(197, 408, 204, 462, 392, 465, 398, 408);
ellipse(248, 437, 59, 63);
ellipse(278, 437, 59, 63);

//draw text for cup
textSize(50);
textStyle(BOLD);
fill(255, 255, 255);
text("CUP", 248, 400);

//draw text for noodles
textSize(38);
textStyle(BOLD);
fill(255, 255, 255);
text("NOODLES", 203, 450);

//draw nissin logo with text
fill(177, 27, 38);
arc(208, 357, 36, 38, PI, TWO_PI);
textSize(8);
fill(255, 255, 255);
text("NISSIN", 195, 354);

//bottom red line
strokeWeight(1);
stroke(198, 58, 61);
line(210, 535, 386, 536);

//top red line
line(175, 289, 428, 291);

//white shine on cup
fill(255, 255, 255, 90);
noStroke();
quad(373, 272, 348, 568, 375, 564, 407, 272);
}

 

This project was pretty fun for me, though I did not know where to start with the commands and which commands to choose to make my code do what I wanted it to do. I enjoyed creating the cup of noodles especially, since I always eat cup noodles.

jknip-SectionA-LookingOutwards-03

MIT Media Lab Silk Pavilion

“Silk Pavilion” by Mediated Matter / MIT Media Lab (2013)

Silk Pavilion was an architectural experiment conducted with 6,500 live silkworms. Mediated Matter led by Neri Oxman, studied productivity in nature in conjunction with computerized efficiency in fabrication. I admire how the group found an intersection across the artificial and natural, and was able to effectively apply fabrication understanding across such a large scaled dome installation. What’s also really admirable is how Oxman decided to develop custom CAD tools for the project, specifying specific thread properties of the pavilion that couldn’t have been altered elsewhere.

Using an algorithm inspired by the silkworm’s natural ability to create cocoons out of thread, the system assigns single threads across patches with varying density levels. Silkworms were then physically deployed as a real-time “3D printer”. The final form was not fully controlled by the creators, as the texture and features of the dome were difficult to predict due to the emergent behavior of the worms. Through deep understanding of silkworms as a medium, the group learned how to utilize them as a sophisticated, multi-axis printing medium.

SILK PAVILION from Mediated Matter Group on Vimeo.

https://www.media.mit.edu/projects/silk-pavilion/overview/

https://vimeo.com/67177328

adev_looking outwards_03

Living Mushtari

This piece is by the Mediated Matter Group at the MIT Media Lab. I find there work to be extremely groundbreaking and extremely relevant. They play with biology and synthetic fabrication, how the synthetic and the organic can come together to augment the way we live. I think this is a crucial part of sustainable innovation.

This project in particular involves microbes attached —via a 3D printed belt— to the body. Once these microbes are exposed to sunlight, they create by products that are supposed to compliment the human body. I think synthetic symbiosis is a very poetic lens through which we can solve very real problems. The organic and the inorganic fuse to create something that helps sustain life, by replicating mechanisms of life. I think that is a very evolved, nuanced relationship.

akluk – Section A – Looking outwards-03

The project is called Rocaille, by Benjamin Dillenburger. No date was specified in the project.

His project seems to be reminiscent of shapes and patterns similar to shells. What I admire about this is the amount of detail in this project. Each surface is created with multiple small twigs of plastic. While I am not sure what algorithms are used to create this piece of artwork, but it seems to remind me fractals and creating smooth surfaces with numerous discrete pieces. The artist seems to have a style for creating very curvy and smooth structures through mathematical and calculated means. We often do not think about art as a very mathematical and calculated way, but this is equally beautiful and logical.

Rocailles

Sijings-project03-DynamicDrawing

Sijings-project

//Clair(sijing) Sun
//session C
//sijings@andrew.cmu.edu
//Project-03-Dynamic Drawing

var moonposX=540;//moon position
var moonposY=140;
var moonR=80;
var frontTX1=300;//front mountain1
var frontTY1=260;
var frontTX2=250;//front mountain2
var frontTY2=260;
var frontTX3=350;//front mountain3
var frontTY3=260;
var front2TX1=250;
var front2TY1=260;
var front2TX2=200;
var front2TY2=260;
var front2TX3=300;
var front2TY3=260;
var islandDegree1=180;//island
var islandDegree2=90;
var islandPosX1=300;
var islandPosY1=250;
var islandWidth=390;
var islandHeight=390;
var backTX1=200;//back mountain1
var backTY1=260;
var backTX2=160;
var backTY2=260;
var backTX3=240;
var backTY3=260;
var back2TX1=180;//back mountain2
var back2TY1=260;
var back2TX2=104;
var back2TY2=260;
var back2TX3=254;
var back2TY3=260;
var moonColor1=156;
var moonColor2=193;
var offsetFish=20;//for fish to follow with a distance
var color1=243;//change color when mouse arrive the moon
var color2=244;
var color3=225;
var bird=0;//a condition for mouse in and outside of the island 



function setup() {
    createCanvas(640, 480);
    
}
 
function draw() {
    background(color1,color2,color3);
    noStroke();
    fill(moonColor1,moonColor2,204);
    moonColor1+=mouseY/400;//moon color change
    //print("bird"+bird);for debugging
    if (moonColor1>=254&bird>0){//moon color changing as mouse moves
        moonColor1=mouseX;
        moonColor2=mouseY;
    }
    var moveMouse=mouseX-500;//to create moon rotatons
    moonposX+=moveMouse;
    if (moveMouse>30&bird>0){//two edge cases
        moveMouse=5;
    }
    if (moonposX<5&bird>0){
        moonposX=635;
    }
    if (moonposX>635&bird>0){
        moonposX=5;
    }

    if (mouseX>470&mouseX<530&&mouseY<163&&mouseY>93){
        color1=224;//background color change
        color2=125;
        color3=105;

    }else{
        color1=243;
        color2=244;
        color3=225;
    }
    if (bird==0&back2TY1<305){//for mountains disappear
        back2TY1+=1;
        backTY1+=1;
        frontTY1+=1;
        front2TY1+=1;
    }else{//for the mountains appear
            back2TY1-=1;
            backTY1-=1;
            frontTY1-=1;
            front2TY1-=1;
            if (back2TY1<45){//to stop mountain from moving further
                back2TY1=45;
            }
            if(backTY1<30){
                backTY1=30;
            }
            if (frontTY1<90){
                frontTY1=90;
            }
            if (front2TY1<110){
                front2TY1=110;
            }


    }

    //mountains
    ellipse(moonposX,moonposY,moonR,moonR);
    fill(222,226,227);
    triangle(back2TX1,back2TY1,back2TX2,back2TY2,back2TX3,back2TY3);
    translate(100,0);
    triangle(back2TX1,back2TY1,back2TX2,back2TY2,back2TX3,back2TY3);
    translate(-100,0);
    fill(163,180,90);
    triangle(backTX1,backTY1,backTX2,backTY2,backTX3,backTY3);
    fill(65,69,41);
    triangle(frontTX1, frontTY1, frontTX2, frontTY2, frontTX3, frontTY3);
    fill(93,105,57);
    triangle(front2TX1, front2TY1, front2TX2, front2TY2, front2TX3, front2TY3);
    fill(90,139,157);
    angleMode(DEGREES);
    arc(islandPosX1, islandPosY1, islandWidth, islandHeight, 0, islandDegree1,islandDegree2);
    

    if (mouseX>106&mouseX<494 && mouseY>251){//for determining wether the mouse is on the island
        fill(175,215,198,100);
        bird=0;
    }else{
        fill(175,215,198);
        bird=1;
    }

    //fish drawings
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(-20,5);//for multiple fishes 
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(-20,5);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(-25,0);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(30,35);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(20,-25);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(25,-10);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);
    translate(10,10);
    arc(mouseX-offsetFish, mouseY+offsetFish, 30,30,0,100,130);
    arc(mouseX-offsetFish-9, mouseY+offsetFish+14.5, 10,10,0,100,130);

    //rotating the boat on the water
    if (bird>0){
        var degree=cos(mouseX);
        rotate(degree);
        //print(degree);for debugging the boat rotation
        fill(104,76,16);
        arc(400, 220, 50,30, 0, islandDegree1,islandDegree2);
    }
    

}

For this project, my idea is to create a narrative drawing where the audience can control the pace by either putting the mouse outside of the lake and inside of the lake. The project is intended that the audience start by putting their mouses inside the lake and then gradually towards the outside. The fish group is always following the mouse. When the fish jumps out of the lake, the mountain grows up and the boat appears. The users can also manipulate the speed that the moon/the sun rotates. When the mouse(in my drawing, the fish group) meet the original point of the sun, the background color will change. Four variables here are 1. the color of the moon 2. the background color 3. the speed of moon’s rotation 4. the rotation angle of the boat (slightly to create the effect of its floating) 5. the size of the mountain 6. the location and the color of the fish.

agusman-Project03-DynamicDrawing

sketch

// Anna Gusman
// Section A
// Project 03
// This code is a bouncy-bodied, color-changing brush concept.
// Referencing properties of spring and damping forces from p5, I create a brush shape
// that organically changes dimensions as the mouse is dragged. 

var centerX = 0.0, centerY = 0.0; // center point of the polygon

var radius = 45, rotAngle = -30;
var accelX = 0.0, accelY = 0.0;
var deltaX = 0.0, deltaY = 0.0;
var springing = 0.0009, damping = 0.98;
//values of the spring and damp forces that make the triangle speed up and slow down when following the mouse.
//
var rr = 10;
var gg= 10;
var bb= 10;
var colorchange = 90;

//dictate the number of nodes
var nodes = 3;

//create zero fill arrays
var nodeStartX = [];
var nodeStartY = [];
var nodeX = [];
var nodeY = [];
var angle = [];
var frequency = [];

// soft-body dynamics
var organicConstant = 1.0;

function setup() {
  createCanvas(600, 400);

  //center shape in window
  centerX = width/2;
  centerY = height/2;

  //initialize arrays to 0
  for (var i=0; i<nodes; i++){
    nodeStartX[i] = 0;
    nodeStartY[i] = 0;
    nodeY[i] = 0;
    nodeY[i] = 0;
    angle[i] = 0;
  }

  // iniitalize frequencies for corner nodes
  for (var i=0; i<nodes; i++){
    frequency[i] = random(5, 12);
  }

  frameRate(60); //increase the drawing speed
}

function draw() {
  //fade the background
  // fill(255, 10);
  // background(200, 3);
  fill(rr, gg, bb); //color of polygon
    rr = 127.5*cos(2*PI*colorchange/360) + 127.5;
    gg = 127.5*sin(2*PI*colorchange/360) + 127.5;
    bb = 127.5*sin(2*PI*(colorchange-20)/360) + 127.5;

colorchange++;
  stroke(0);
  drawShape();
  moveShape();
}

function drawShape() {
  //  calculate the locations of the nodes
  for (var i=0; i<nodes; i++){
    nodeStartX[i] = centerX+cos(radians(rotAngle))*radius;
    nodeStartY[i] = centerY+sin(radians(rotAngle))*radius;
    rotAngle += 360.0/nodes; //drawing 3 points on the circumference of the circle
  }

  // draw polygon
  curveTightness(organicConstant);
  beginShape();
  for (var i=0; i<nodes; i++){
    curveVertex(nodeX[i], nodeY[i]);
  }
  for (var i=0; i<nodes-1; i++){
    curveVertex(nodeX[i], nodeY[i]);
  }
  endShape(CLOSE);
}

function moveShape() {
  //move the center point
  deltaX = mouseX-centerX;
  deltaY = mouseY-centerY;

  // create springing effect
  deltaX *= springing;
  deltaY *= springing;
  accelX += deltaX;
  accelY += deltaY;

  // move the polygon's center
  centerX += accelX;
  centerY += accelY;

  // slow down springing so that the polygon does not continue moving infinitely
  accelX *= damping;
  accelY *= damping;

  // change the tightness of the curves using the organic constant
  organicConstant = 1-((abs(accelX)+abs(accelY))*0.1);

  //move the nodes
  for (var i=0; i<nodes; i++){
    nodeX[i] = nodeStartX[i]+sin(radians(angle[i]))*(accelX*2);
    nodeY[i] = nodeStartY[i]+sin(radians(angle[i]))*(accelY*2);
    angle[i] += frequency[i];
  }
}

For this project, I created an bouncy-bodied, color-changing brush concept. I referenced p5’s softbody dynamics example in order to see how they treated oscillating vector forces. You can find the example here

I was inspired to create a brush concept from the bit of code I wrote in this week’s recitation lab on creating a mouse controlled spiraling ellipse. I first made iterations on this to explore styling options and effects.

Example:

Example:

Still, the brush felt more controlled and predictable than I wanted to to be- I wanted there to be a larger element of surprise. Elements of the soft body dynamics example allowed me to soften the reactions of my shape/brush by giving it springing and damping properties, created by controlling the relationships between the drawn vertexes(nodes) of the shape (curveTightness and curveVertex. This makes the brush wiggle and have a pleasing, natural element to it’s movement. I then control the number of vertexes and sides of the shape and the acceleration and movement of these vertexes. (accel, delta, springing, damping, nodeStart, node).

Next I wanted to illustrate change across the movement of the brush path. I did this by creating a color system that undulates across the length of 3 sine waves, one each for red, blue and green.

I also experimented further with eliminating or altering the spring relationship between the mouse and the center of the polygon. Here is one example:

In future iterations of this brush concept, I’d like to embed customization of the brush shape so that when you click, you could alter the number of vertexes that would result in different brush trails. Definitely excited to play around with this more, as it has been a great learning experience.