Project-10

sketch
//Diana McLaughlin, dmclaugh@andrew.cmu.edu, Section A
//story project - a cat wanders around the house in search of dinner and runs into other characters - each more unlikely to live in the house than the last

var meow;
var bark;
var buzz;
var angry;
var aln;
var door;
var nom;

function preload() {
    meow = loadSound("http://127.0.0.1:8887/meow.wav");
    bark = loadSound("http://127.0.0.1:8887/bark.wav");
    buzz = loadSound("http://127.0.0.1:8887/fly.wav");
    angry = loadSound("http://127.0.0.1:8887/angry.wav");
    aln = loadSound("http://127.0.0.1:8887/alien.wav");
    door = loadSound("http://127.0.0.1:8887/door.wav");
    nom = loadSound("http://127.0.0.1:8887/nom.wav");
}


function setup() {
    createCanvas(400, 400);
    frameRate(1);
    createDiv("p5.dom.js library is loaded.");
    textSize(16);
    textAlign(CENTER);
    useSound();
}


function soundSetup() { // setup for audio generation
    meow.setVolume(1);
    bark.setVolume(1);
    buzz.setVolume(1);
    angry.setVolume(1);
    aln.setVolume(1);
    door.setVolume(1);
}


function draw() {
    // you can replace any of this with your own code:
    background(0, 200, 255);
    if (frameCount <= 8) {
        cat(width/2, height/2);
        thoughtBubble(300, 75);
        foodbowl(300, 75);
        stroke(0);
        text('Where is my dinner?', width/2, 325);
        text('I have never eaten in my life', width/2, 350);
        meow.play();
    }

    if (frameCount > 8 & frameCount <= 13) {
        cat(100, 200);
        dog(300, 200);
        text('Dog, have they fed you?', width/2, 325);
        text('Dinner is not for another hour, Cat', width/2, 350);
        if (frameCount <= 7) {
            meow.play();
        } else {
            bark.play();
        }

    }

    if (frameCount > 13 & frameCount <= 18) {
        cat(150, 300);
        fly (300, 300);
        text('Fly, have you eaten', width/2, 25);
        text('I just got here, I was on Mike`s head', width/2, 50);
        if (frameCount <= 12) {
            meow.play();
        } else {
            buzz.play();
        }
    }

    if (frameCount > 18 & frameCount <= 21) {
        text('The cat wandered so far away from the kitchen', width/2, height/2);
        text('that he found an alien', width /2, height/2 + 25);
    }

    if (frameCount > 21 & frameCount <= 26) {
        cat(300, 150);
        alien(100, 150);
        text('Alien I will starve if no one feeds me', width/2, 325);
        text('Go back to the kitchen, Cat.', width/2, 350);
        text('You still have 20 minutes until dinner', width/2, 370);
        if (frameCount <= 20) {
            angry.play();
        } else {
            aln.play();
        }
    }

    if (frameCount > 26 & frameCount <= 29) {
        text('Dejected and starving, cat made the long journey', width/2, height/2);
        text('from the closet back to the kitchen', width/2, height/2 + 25);
        angry.play();
    }

    if (frameCount > 29 & frameCount <= 32) {
        text('Suddenly, Cat heard a noise', width/2, height/2);
    }

    if (frameCount > 32 & frameCount <= 37) {
        surprisedcat(width/2, height/2);
        text('Could it be? Is the human home to save me?', width/2, 325);
        if (frameCount <= 32) {
            door.play();
        } else {
            meow.play();
        }
    }

    if (frameCount > 37) {
        cat(width/2, height/2);
        foodbowl(width/2, height/2 + 18);
        nom.play();
    }
}

function cat(x, y) {
    push();
    translate(x, y);
    noStroke();
    fill(200);
    ellipse(0, 0, 100, 100); //head
    triangle(-10, -49, -28, -70, -35, -35); //ears
    triangle(10, -49, 28, -70, 35, -35);
    fill(255, 0, 50);
    triangle(-13, -47, -26, -60, -30, -40);
    triangle(13, -47, 26, -60, 30, -40);
    fill(0, 255, 0);
    ellipse(-20, -20, 12, 12); //eyes
    ellipse(20, -20, 12, 12);
    fill(0); 
    ellipse(-20, -20, 7, 7);
    ellipse(20, -20, 7, 7);
    fill(255, 0, 50);
    stroke(0); //nose & mouth
    triangle(0, 5, -7, -3, 7, -3);
    line(0, 5, 0, 12);
    line(0, 12, -12, 20);
    line(0, 12, 12, 20);
    line(35, 5, 75, 5); //whiskers
    line(35, 5, 75, -5);
    line(35, 5, 75, 15);
    line(-35, 5, -75, 5);
    line(-35, 5, -75, -5);
    line(-35, 5, -75, 15);
    pop();
}

function dog(x, y) {
    push();
    translate(x, y);
    noStroke();
    fill(180, 100, 100);
    ellipse(0, 0, 110, 140); //head
    triangle(-11, -68, -29, -91, -36, -53); //ears
    triangle(11, -68, 29, -91, 36, -53);
    fill(0);
    ellipse(-20, -20, 13, 13); //eyes
    ellipse(20, -20, 13, 13);
    ellipse(0, 10, 25, 15); //nose
    stroke(0);
    strokeWeight(2);
    line(-20, 30, 20, 30); //mouth
    noStroke();
    fill(255, 0, 50);
    rect(10, 30, 10, 5);
    ellipse(15, 35, 10, 8);
    noStroke();
    fill(255, 0, 0); //collar
    rect(-45, 65, 90, 20);
    fill(255, 255, 0);
    ellipse(0, 90, 20, 20);
    pop();
}

function fly(x, y) {
    push();
    translate(x, y);
    fill(0);
    ellipse(0, 0, 45, 75); //body
    fill(55);
    push(); //wings
    rotate(radians(45));
    ellipse(-14, 15, 30, 45);
    pop();
    push();
    rotate(radians(315));
    ellipse(14, 15, 30, 45);
    pop();
    pop();
}

function alien(x, y) {
    push();
    translate(x, y);
    noStroke();
    fill(0, 255, 0);
    ellipse(0, 0, 95, 150); //head
    rect(-30, -100, 8, 70); //antenna
    rect(22, -100, 8, 70);
    fill(0);
    ellipse(-20, -20, 15, 25); //eyes
    ellipse(20, -20, 15, 25);
    stroke(0);
    strokeWeight(5);
    line(-30, 30, 30, 30); //mouth
    pop();
}

function foodbowl(x, y) {
    push();
    translate(x, y);
    ellipseMode(CENTER);
    for (var a = -17; a < 17; a += 4) { //food
        fill(180, 50, 80);
        ellipse(a, -11, 4, 4);
    }
    rectMode(CENTER);
    fill(255, 0, 0);
    rect(0, 0, 40, 20); //bowl
    pop();

}

function surprisedcat(x, y) {
    push();
    translate(x, y);
    noStroke();
    fill(200); //head
    ellipse(0, 0, 100, 100);
    triangle(-10, -49, -28, -70, -35, -35); //ears
    triangle(10, -49, 28, -70, 35, -35);
    fill(255, 0, 50);
    triangle(-13, -47, -26, -60, -30, -40);
    triangle(13, -47, 26, -60, 30, -40);
    fill(0, 255, 0); //eyes
    ellipse(-20, -20, 12, 12);
    ellipse(20, -20, 12, 12);
    fill(0); 
    ellipse(-20, -20, 7, 7);
    ellipse(20, -20, 7, 7);
    fill(255, 0, 50); //nose
    stroke(0);
    triangle(0, 5, -7, -3, 7, -3);
    fill(0);
    ellipse(0, 16, 10, 10); //mouth
    line(35, 5, 75, 5); //whiskers
    line(35, 5, 75, -5);
    line(35, 5, 75, 15);
    line(-35, 5, -75, 5);
    line(-35, 5, -75, -5);
    line(-35, 5, -75, 15);
    pop();
}

function thoughtBubble(x, y) {
    push();
    translate(x, y);
    fill(255);
    ellipse(-50, 50, 12, 12);
    ellipse(-36, 36, 12, 12);
    ellipse(-22, 22, 12, 12);
    ellipse(0, 0, 60, 45); //biggest bubble
    pop();
}

I was working on this while my cat was waiting for dinner (over an hour early) and it gave me this idea

LO – 11

Camille Utterback is from Bloomington, Indiana and attend Williams College for undergrad and NYU for a master’s within the school of art. She is known as an interactive installation artist, and has worked as a contractor for many art exhibits.

Camille Utterback’s piece, “Precarious”, utilizes a ceiling mounted camera with KinectV2 camera tracking to draw silhouettes on a backlit screen. Her work was created for and installed in the National Portrait Gallery exhibition Black Out:Silhouettes Then and Now that opened on May 18, 2018. The Gallery and Raphael Palefsky-Smith, developer of the cameras, helped Utterback create this work of art.

Precarious was built on the  algorithmically generated visual language that she has spent many years refining with her custom coded interactive drawing system. While not much is spoken about her custom software it creates very cool and interactive artwork for others to enjoy. This piece, specifically, does more than just trace those who visit the installation on the backlit screen. As people play with the piece more and more they realize that when more than one person is present each person can alter the other’s silhouette by pushing it and manipulating it with their own outline. Additionally, past outlines erase after one leaves and others join.

I found this to be a funky and inspiring way to represent history as it both represents and deviates from the popularity of silhouettes back in the day. While silhouettes were a form of art, they generally only had one person in the frame. This piece makes that impossible, but aligns with how important relationships are versus back then, as in more and more people care about each other and the future of the World.

Here’s a video representation of the piece:

You can check out a more complete story on the piece here:

LookingOutwards-10

LINES is an interactive musical instrument which is one of the most inviting and famous piece in the Tate Modern Museum. No musical experiences are required to perform this sound art which makes it constantly surrounded by kids to play with it. The five lines painted in different color on the wall are connected with different harmonies. By placing hands on different lines, the audience can enjoy this free, casual and playful music made by their own. The exhibition is created by the Swedish composer Anders Lind who has created a series of interactive sound art with simplicity. The combination of programming sensors and colors allow the audience to experience the fine line between “sound” and “music” freely and subtly.

Video Link: https://www.youtube.com/watch?v=hP36xoPXDnM

Project : 10

For this project I decided to create the view of a campsite from sunrise to sunset with people, the bonfire, a tent, clouds stars and of course some singing! For the sounds I did try to make them overlap a little so that it sounds more interesting when played.

sketch
//Aadya Bhartia 
//Section A 
//abhartia@andrew.cmu.edu

/*Through my sonic story I wanted to show a view of a campsite where you hear
the birds in the morning and the the head comes to wake you up and then some 
music and bonfire in the evening followed by a lullaby*/

//varibales for sounds 
var bird;
var wakeUp;
var tent;
var guitar;
var bonfire;
var lullaby;
//to store the images 
var Sceneimage = [];
function preload() {
    // call loadImage() and loadSound() for all media files here
    var filenames = [];
    filenames[0] = "https://i.imgur.com/ITiizfB.png";
    filenames[1] = "https://i.imgur.com/tuuMWhz.png";
    filenames[2] = "https://i.imgur.com/jwZrzv0.png";
    filenames[3] = "https://i.imgur.com/tpb0sAu.png";
    filenames[4] = "https://i.imgur.com/ZFtXPrz.png";
    filenames[5] = "https://i.imgur.com/IsF4NuT.png";
    filenames[6] = "https://i.imgur.com/ttnjMNJ.png";
    filenames[7] = "https://i.imgur.com/V0Lf0an.png";
    filenames[8] = "https://i.imgur.com/vt9fZjI.png";
    filenames[9] = "https://i.imgur.com/pji8Wnc.png";
    //loading images into the array 
    for (var i = 0; i < filenames.length; i++) {
        Sceneimage[i] = loadImage(filenames[i]);
    }
    //load sounds 
    bird = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/birds-1.wav");
    wakeUp = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/wake-up.wav");
    tent = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/tent.wav");
    guitar = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/guitar-3.wav");
    bonfire = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/bonfire.wav");
    lullaby = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/lullaby.wav");
}

function setup() {
    createCanvas(614, 345);
    frameRate(1);
    useSound();
}
function soundSetup() { // setup for audio generation, chnaging volumes 
    bird.setVolume(0.1);
    wakeUp.setVolume(1);
    guitar.setVolume(0.1);
    lullaby.setVolume(0.2);
}
function draw() {
    //sun rising 
    if(frameCount>=0 & frameCount< 4){
        image(Sceneimage[0], 0,0, 614, 345);
        bird.play();
    }
    //sun up and clouds come in 
    if(frameCount>=4 & frameCount< 8){
        image(Sceneimage[1], 0,0, 614, 345);
        //creating a cloud animation for the different frames 
        if(frameCount== 4){
            image(Sceneimage[9], 0,0, 614, 345);
        }
        if(frameCount== 5){
            image(Sceneimage[9], width/4,0, 614, 345);
        }
        if(frameCount== 6){
            image(Sceneimage[9], width/2,0, 614, 345);
        }
        if(frameCount== 7){
            image(Sceneimage[9], (3*width/4),0, 614, 345);
        }
        bird.play();
    }
    //head comes to wake up 
    if(frameCount>=9 & frameCount< 11){
        image(Sceneimage[2], 0,0, 614, 345);
        wakeUp.play();
    }
    //tent open and girls head pops out 
    if(frameCount>=11 & frameCount< 12){
        image(Sceneimage[3], 0,0, 614, 345);
        tent.play();
    }
    //couple playing the guitar 
    if(frameCount>=12 & frameCount< 17){
        image(Sceneimage[4], 0,0, 614, 345);
        guitar.play();
    }
    //fire lights up
    if(frameCount>=17 & frameCount< 20){
        image(Sceneimage[5], 0,0, 614, 345);
        bonfire.play();
    }
    //fire becomes bigger 
    if(frameCount>=20 & frameCount< 25){
        image(Sceneimage[6], 0,0, 614, 345);
        guitar.play();
        bonfire.play();
    }
    //head comes to say time to go to bed 
    if(frameCount>=25 & frameCount< 28){
        image(Sceneimage[7], 0,0, 614, 345);
        
    }
    //lullaby and stars 
    if(frameCount>=28 & frameCount< 40){
        image(Sceneimage[8], 0,0, 614, 345);
        lullaby.play();
        //creating jittering stars at night 
        star(random(0,width),random(0, height/2));
        star(random(0,width),random(0, height/2));
        star(random(0,width),random(0, height/2));       
    }
}
//star code from class lecture : 14 
function star(a,b){
    var x = [50, 61, 83, 69, 71, 50, 29, 31, 17, 39];
    var y = [18, 37, 43, 60, 82, 73, 82, 60, 43, 37];
    var nPoints = x.length;
    fill(255, 255, 0);
    translate(a,b);
    scale(random(0.1,0.5));//scaling the stars at random
    beginShape();
    for (var i = 0; i < nPoints; i++) {
    vertex( (x[i]) + random(-3,3), (y[i]) + random(-3,3) ); //random creates jitter effect
    }
    endShape(CLOSE);
}

Project 10

For this week’s project, I decided to depict a chill night in that someone might have with their cats in a living room. I was feeling a bit stressed because of my classes, so I tried to go for more of a chill vibe that took various aspects of my existing room and blended them with auditory elements.

I did the initial drawings in illustrator, and imported each part as a different image.

sketchDownload
// Susie Kim
// susiek@andrew.cmu.edu
// Section A
// Project 10

// call global variables
var bgPhoto;

var cupcake;
var cupcakeX = 280;
var cupcakeY = 360;

var pointedHand;
var pointedHandX = 230;
var pointedHandY = 450;

var grabbingHand;
var grabbingHandX = 280;
var grabbingHandY = 450;

var tvScreen;
var musicNotes;
var mouth;

var count = 0;

var meow;
var tvTurnOn;
var eat;
var musicPlay;

function preload() {
    // load images
    bgPhoto = loadImage('https://i.imgur.com/SJVApbw.jpg');
    cupcake = loadImage('https://i.imgur.com/muqUIC2.png');
    pointedHand = loadImage('https://i.imgur.com/3HCNg3e.png');
    grabbingHand = loadImage('https://i.imgur.com/375PW9c.png');
    musicNotes = loadImage('https://i.imgur.com/FVRrvrB.png');
    tvScreen = loadImage('https://i.imgur.com/7mrIDoW.png');

    meow = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/catmeow.wav");
    tvTurnOn = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/tvsound.wav");
    eat = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/eating.wav");
    musicPlay = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/music1.wav");

}

function setup() {
    // you can change the next 2 lines:
    createCanvas(400, 400);
    frameRate(4);
    imageMode(CENTER);
    useSound();
}

function soundSetup() { // setup for audio generation
    meow.setVolume(1);
    tvTurnOn.setVolume(1);
    eat.setVolume(1);
    musicPlay.setVolume(1);
}

function draw() {
    count++; // add 1 frame for each time draw function runs

    image(bgPhoto, width/2, height/2, width, height); // set up background photo

    // have a hand come and take the cupcake on the table
    if (count >= 0 & count < 100) {
        image(cupcake, cupcakeX, cupcakeY, 40, 40); // place cupcake in scene
        image(grabbingHand, grabbingHandX, grabbingHandY, 100, 100); // place hand outside of scene, ready to grab
    }
    if (count > 30 & count < 45) { // bring hand into frame
        grabbingHandY -= 5;
    }
    if (count > 45 & count < 100) { // have hand take cupcake
        cupcakeY += 5;
        grabbingHandY += 5;
    }

    // eating sound from the person eating the cupcake
    if (count == 100) {
        eat.play();
    }

    // have both cats meow with mouths open
    catMouth();
    if (count >= 0 & count < 125) { // have mouths regular
        mouth = true;
    }
    if (count > 125 &  count < 155) { // have mouths open with meow sound
        mouth = false;
    }
    if (count == 126) {
        meow.play();
    }
    if (count > 155) { // mouths return back to normal after meow
        mouth = true;
    }

    // have hand come and touch remote to turn tv off
    tvOn();
    if (count >= 0 & count < 155) { // keep screen on
        screen = true;
    }
    if (count > 165 & count < 172) { // screen turns off as hand moves away
        screen = false;
        pointedHandY += 7;
    }
    if (count == 166) {
        tvTurnOn.play();
    }

    image(pointedHand, pointedHandX, pointedHandY, 100, 100);
    if (count > 140 & count < 155) { // hand comes to click remote
        pointedHandY -= 5;
    }

    // have hand come and touch remote again to play music on record player
    if (count > 165 & count < 173) { // hand comes to push button
        pointedHandX = 236;
        pointedHandY -= 5;
    }
    if (count > 185 & count < 213) { // hand moves away
        pointedHandY += 5;
    }
    if (count > 174) { // show music notes and play music
        image(musicNotes, 80, 70, 50, 50);
    }
    if (count == 175) {
        musicPlay.play();
    }
}

function tvOn() {
    if (screen == true) { // tv shows pink screen with flower when on
        image(tvScreen, 205, 145, 135, 90);
    }
    if (screen == false) { // tv is black when off
        fill(0);
        rectMode(CENTER);
        rect(205, 145, 134, 80, 8);
    }
}

function catMouth() {
    strokeWeight(.5);
    stroke(0);
    noFill();

    if (mouth == true) { // mouth closed when sitting
        line(220, 307, 225, 307); // white cat
        line(81, 276, 84, 276); // orange cat

    } else if (mouth == false) { // mouth open when meowing
        ellipse(223, 307, 5, 5); // white cat
        ellipse(83, 276, 3, 3); // orange cat

        // sound marks for white cat
        strokeWeight(1);
        stroke(255, 255, 0);
        line(260, 280, 270, 265);
        line(250, 280, 250, 265);
        line(240, 283, 230, 268);

        // sound marks for orange cat
        line(60, 238, 60, 251);
        line(50, 251, 45, 238);
        line(43, 253, 30, 240);
    }
}

LO-10 (computer music)

For this LO I’ll be looking at a service that provides computer generated music for creative users.This service/machine/Ai is called AIVA. The service allows you to set various parameters including instruments, tempo, etc. or completely randomized if left blank. The resulting music created actually sounds quite professional and due to its random nature, it will not likely create the same track twice. To ensure that, AIVA uses stochastic algorithms to randomize each of its elements to allow for ‘original’ creations every single time. Looking through each sample created for each genre, I wouldn’t be able to tell the difference between aiva and a professional track.

https://www.aiva.ai

PROJECT-10 (sonic story)

sketch
// 15-104
// SEAN CHEN
// A person running in the rain rushes toward a gathering indoors
// and suddenly the person busts through the window causing panic.

var rain, running, panting, group, intrain, scream, glass;
var note = 0;
var walkImage = [];
var filenames = [];


// various sounds
function preload() {
    rain = loadSound ('http://127.0.0.1:5500/handin10/seanc1-10-project/sounds/-combo.wav');
    group = loadSound ('http://127.0.0.1:5500/handin10/seanc1-10-project/sounds/-combo-group.wav');
    scream = loadSound ('http://127.0.0.1:5500/handin10/seanc1-10-project/sounds/-group-scream.wav');
    glass = loadSound ('http://127.0.0.1:5500/handin10/seanc1-10-project/sounds/-glass-smash.wav');
}

function setup() {
    createCanvas(600, 300);
    frameRate(15);
}

function soundSetup() {}

// apartment building
function house() {
    push();
    fill(150);
    rect(525, 50, 100, 250);
    fill(244,202,41);
    rect(550, 75, 50, 50);
    rect(550, 150, 50, 50);
    rect(550, 225, 50, 50);
    pop();
}

// rain
function rainfall() {
    stroke(255);
    strokeWeight(0.5);
    for (var x = 0; x < width; x += 5) {
        for (var y = 0; y < height; y += 10) {
            line(x, y, x, y+5);
        }
    }
}

// shadowy figure
function figure(x, y) {
    push();
    fill(0);
    rect(x, y+275, 10, 50);
    ellipse(x+5, 265, 10, 10);
    pop();
}

function draw() {
    background(50);
    // drawing shadowy figure running through rain, into the 1F window
    house();
    if (frameCount < 170) {
        var xpos = map(frameCount, 0, 170, 0, 550);
        figure(xpos, 0);
    }
    push();
    if (frameCount % 3 == 0) {
        translate(random(0, 3), 5);
    }
    rainfall();
    pop();


    var seq = [rain, group, rain, group, rain, group] // event sequence
    var dur = [5, 48, 45, 30, 15, 15]; // event duration

    if (frameCount % dur[note] == 0) { // play time based on frames
        if (note > 0) {
            seq[note-1].stop();
            seq[note].play();  
        }
        seq[note].play();
        note++;
    }
    if (note == seq.length) { // final glass smash
        glass.play(1);
        scream.play(1.3);
        seq[note-1].stop(1.5);
        var totalFrames = frameCount;
        note++;
    }

    if (frameCount == totalFrames+30) {
        noLoop();
    }
    print(frameCount);
}

LO-10

For this week’s LO, I decided to look into Imogen Heap’s “Mi Mu Gloves”, an idea of hers that was originally conceived in 2010 but only recently was able to be fabricated and prototyped for public consumption. Heap, originally only a musician, wanted to create the product to bring electronic music to another level, allowing artists to step away from their immobile instruments and connect with the audience. The gloves themselves have a mass amount of flex sensors, buttons, and vibrators that come together to simulate the feeling and sounds of real instruments. The gloves correspond over wifi with a dedicated software and algorithm that reads the movements of the wearer and translates them into sounds, depending on what the user records as inputs. 

It was interesting to see how technology has come as far to allow a musician to play instruments without having the physical instrument in front of them. I admire Heap’s ability to bring her dreams, which she dreamt up in 2010, to reality, even with barriers that existed, and the flexibility that the gloves could provide even to people with physical disabilities that don’t allow them to play instruments. This is demonstrated by Kris Halpen, whose life as a musician has been dramatically affected as a result of the Mi Mu gloves.

LO-10: Computer Music

The project I chose is The Welcome Chorus by Yuri Suzuki. This project is an interactive installation in the county of Kent commissioned by the Turner Contemporary consisting of 12 horns that continuously sing AI generated lyrics. What I admire most about this project, like for most of Suzuki’s other works, is its ability to blend sound and technology to produce music in unconventional ways that are easily accessible to anyone and everyone. The lyrics, reflecting the people’s experiences living in Kent and Kent as a whole, were gathered from workshops and gatherings and put into a data bank in which the AI algorithms learned from to produce the lyrics that will be sung. Another AI system was integrated in order to produce folk song melodies so that the installation can produce songs with both lyrics and melodies. Suzuki’s artistic sensibilities are manifested in the final form since, like his other works, he turns this complex project into an interactive sculpture that any visitor can contribute to (using an ongoing machine learning “conductor”) and learn from without the extra burden of trying to understand complex ideas.

Yuri Suzuki’s The Welcome Chorus (2020)

Project 10: Sonic Story

sketchDownload
//Nicholas Wong
//Section A
//nwong1@andrew.cmu.edu
//Assignment 10

var angle = 0; //Angle for clock
var catEyes = 0; //Cat eye size
var mousePos = 0; //Mouse position
var mousedx = 5; //Mouse speed

function preload() 
{
    //For use in web upload
   catSound = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/cat.wav");
   mouseSound =loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/mouse1.wav"); 
   clockSound = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/clock.wav");
   thunderSound = loadSound("https://courses.ideate.cmu.edu/15-104/f2020/wp-content/uploads/2020/11/thunder-2.wav"); 

    //For use in localhost
    /*
    catSound = loadSound("cat.wav");
    clockSound = loadSound("clock.wav");
    mouseSound = loadSound("mouse1.wav");
    thunderSound = loadSound("thunder.wav");
    */
}

function soundSetup() 
{ // setup for audio generation
    catSound.setVolume(0.5);
    mouseSound.setVolume(0.4);
    clockSound.setVolume(0.7);
    thunderSound.setVolume(1);
}

function setup() {
    // you can change the next 2 lines:
    createCanvas(480, 480);
    createDiv("p5.dom.js library is loaded.");
    useSound();
    frameRate(1);
    angleMode(DEGREES);
}




function draw() 
{
    background(140,90,50);

    //Backdrop (window, room)
    drawBackdrop();

    //Frame dependant events
    if(frameCount % 7 == 0)
    {
        clockSound.play();
    }

    if(frameCount % 12 == 0)
    {
        drawLightning() //Draw lightning for 1 frame
        catEyes = 6; //Cat eyes are wide open
        mousedx *= -1; //Mouse reverses direction
        thunderSound.play(); //Thunder sound
        catSound.play(); //Meow
    }


    //Window
    windowLines(95,200);
    windowLines(95,260);

    //Objects
    drawDrawer(330,height/2+100);
    drawPainting(400,270);
    drawClock(width/2 + 20,height/2);

    //Cat
    drawCat(340,310);

    //Mouse
    drawMouse(mousePos,430);



}

function drawCat(x,y)
{
    //Cat artwork
    push();
    noStroke();
    ellipseMode(CENTER);
    fill(40);
    ellipse(x+13,y+17,50,30);
    ellipse(x-2,y+25,17,15);
    ellipse(x+30,y+25,15,15);
    fill(40);
    ellipse(x,y,35,30);
    triangle(x-15,y-8,x-5,y-10,x-10,y-23)
    translate(18,0);
    triangle(x-15,y-8,x-5,y-10,x-10,y-23)
    fill(255)

    //Cat eyes
    ellipse(x-10,y,7,catEyes);
    ellipse(x-26,y,7,catEyes);
    pop();

    //Cats eyes decrease in size every frame
    catEyes -= 1;
    

    //Cat eyes minimum size is 1;
    if(catEyes <= 0)
    {
        catEyes = 1;
    }

}

function drawMouse(x,y)
{
    //Mouse artwork
    push();
    noStroke();
    ellipse(x,y,20,10);
    ellipse(x+8,y-3,4);
    triangle(x+5,y-4,x+15,y,x+5,y+4);
    stroke(255);
    strokeWeight(2);
    line(x,y+2,x-20,y+2);
    stroke(0);
    strokeWeight(2);
    point(x+15,y);
    strokeWeight(1.5);
    point(x+9,y-1);
    pop();

    //Play squeak when mouse reaches x=0;
    if(mousePos == 0)
    {
        mouseSound.play();
    }

    //Make mouse stop moving left after x=-15
    if(mousePos <= -15)
    {
        mousePos = -15
    }
    //Add dx to mouse position
    mousePos += mousedx;

}

function drawLightning()
{
    //Lightning artwork
    push();
    translate(random(25,-25),0);
    stroke(0,100,255);
    strokeWeight(3);
    line(90,142,107,160);
    line(107,160,90,190);
    line(90,190,105,220);
    line(105,220,95,250);
    line(95,250,107,280);
    line(90,317,107,280);
    stroke(255);
    strokeWeight(1);
    line(90,141,107,160);
    line(107,160,90,190);
    line(90,190,105,220);
    line(105,220,95,250);
    line(95,250,107,280);
    line(90,317,107,280);
    pop();
}

function drawPainting(x,y)
{   
    //Painting artwork
    push();
    noStroke();
    rectMode(CENTER);
    fill(120,60,0)
    rect(x,y,120,75);
    fill(220);
    rect(x,y,110,65);
    fill(0,170,190);
    circle(x,y,30)
    fill(180,0,150);
    circle(x+30,y+10,20)
    pop();
}

function drawBackdrop()
{
    push();
    noStroke();
    //Floor
    fill(120,70,10);
    rect(0,400,width,80);

    //Ceiling
    fill(120,60,0)
    rect(0,0,width,80);

    //Window
    rect(15,125,160,210);
    fill(170,100,0);
    rect(20,130,150,200);

    //Sky
    fill(52, 49, 69);
    rect(30,140,130,180)
    pop();
}

function windowLines(x,y)
{
    //Window frame stuff
    push();
    noStroke();
    fill(170,100,0);
    rectMode(CENTER);
    rect(x,y,150,7);
    fill(100,50,0);
    rect(x,y+3,130,2)
    pop();
}

function drawDrawer(x,y)
{
    push();
    noStroke();
    fill(170,100,0);
    rect(x,y,143,70);

    //Shadow
    fill(115,65,0)
    rect(x,y+70,143,70)

    //Back
    fill(190,120,0);
    rect(x+7,y+12,130,20);
    rect(x+7,y+40,130,20);

    //Drawers
    fill(220,150,0);
    circle(x+35,y+22,10);
    circle(x+105,y+22,10);
    circle(x+35,y+50,10);
    circle(x+105,y+50,10);
    pop();
}


function drawClock(x,y)
{
    push();
    noStroke();

    //Shadow
    fill(115,65,0);
    rect(x-25,y+150,52,100)

    //Light
    fill(220,150,0);
    circle(x+3,y+70,50);
    rect(x-22,y+70,50,100)
    circle(x+3,y+55,35)

    //Base
    fill(200,120,0);
    circle(x,y+70,50);
    rect(x-25,y+70,50,100)
    circle(x,y+55,35)


    //Shades
    fill(170,100,0);
    circle(x,y+55,25);
    circle(x,y+70,40);
    rect(x-15,y+100,30,65);
    ellipse(x,y+100,30,15);

    //Clock face
    fill(255);
    circle(x,y+70,34);
    fill(0);
    circle(x,y+70,2);

    //Clock Static Hand
    stroke(100);
    strokeWeight(1);
    line(x,y+70,x,y+60)
    
    //Clock Second Hand

    angle+= 6 //Add 6 degrees every frame (second)
    stroke(0);
    strokeWeight(0.5);
    let ax = x+cos(angle) * 14; //Polar x coordinates
    let ay = y+sin(angle) * 14; //Polar y coordinates
    line(x,y+70, ax, ay+70); //Draw clock hand

    //Detail
    stroke(235,180,0);
    strokeWeight(2);

    //Pendulum chime things
    line(x,y+94,x,y+120+abs(10*sin(angle)));
    line(x+4,y+94,x+4,y+100+abs(20*sin(angle)));

    pop();
}

A mouse tries to sneak past a sleeping cat, but the lightning keeps waking the cat up.