rnayyar@andrew.cmu.edu – [OLD – FALL 2016] 15-104 • COMPUTING for CREATIVE PRACTICE https://courses.ideate.cmu.edu/15-104/f2016 Professor Roger B. Dannenberg • Fall 2016 • Introduction to Computing for Creative Practice Sat, 12 Sep 2020 00:19:45 +0000 en-US hourly 1 https://wordpress.org/?v=4.5.31 Rhea Nayyar’s Final Project: “A Girl Dismissed”, the angsty goth twitterbot https://courses.ideate.cmu.edu/15-104/f2016/2016/12/09/rhea-nayyars-final-project-a-girl-dismissed-the-angsty-goth-twitterbot/ https://courses.ideate.cmu.edu/15-104/f2016/2016/12/09/rhea-nayyars-final-project-a-girl-dismissed-the-angsty-goth-twitterbot/#respond Fri, 09 Dec 2016 23:21:10 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=7783 Continue reading "Rhea Nayyar’s Final Project: “A Girl Dismissed”, the angsty goth twitterbot"]]>

My good friend Kate was the inspiration for my twitter bot. No, she’s not a goth queen, but she did a hilarious text generation program that used a computer manual and a Shakespeare play to make computerized sonnets.

https://twitter.com/666sadshawty666 <—- This is the account!!!! It tweets every half hour as long as I keep the program running.

http://imgur.com/gallery/PJLdR <—- These are some of the funniest returns I got from the program. I highly recommend looking through this if you have time but the twitter feed itself should give you a good idea of what the bot has to say.

http://pastebin.com/EufB7Vcz <—- this is a pastebin link that contains
the input text (emobot_words.txt) employed by my program. I collected
these texts from various places:

  •  Twitter itself: I scoured through several tags like “#gothlife”, “#gothproblems”, “#gothculture” and so on and found some amazing content to include in my file.
  • Tumblr: Looking through similar tags on tumblr yielded the same spectacular results.
  • Facebook Groups: Lots of angst-ridden people particularly enjoy airing their grievances on social media it seems.
  • Several Goth Blogs: gothicsubculture.com, www.thebelfry.rip, whatisgoth.com, and many other sites had loads of information about
    the gothic subculture, the stereotypes, history, and the backlash from mainstream society. They were actually pretty educational but all boiled down to the same message. Goths are drawn to darkness and macabre, but are generally happy people.
  • Song Lyrics: All from the popular early 2000s band called Evanescence. Tracks include “My Immortal” and “Wake Me Up”.
  • My Own “Creativity”: It’d be inappropriate, in my opinion at least, to use so many other sources for text generation so I absolutely had to include some of my own angsty poetry and thoughts from years past. I only hope it adds to the authenticity of this bot.

***I appreciate being able to locate and use all this content and this work isn’t intended to be offensive but to merely poke fun at the multi-faceted subculture. I was interested in gothic culture throughout middle school and high school and I’d like to consider this as an homage to my former self.***

There was an issue with creating the Twitter bot with .js file, so I had to switch to Processing entirely. There were some differences in syntax, but
it was relatively easy to adjust the code properly. I had learned some new
functions, too. And what a boolean is. That was very cool. Boolean is good.

ANYWAYS, down to the important stuff: RiTa library. The RiTa library contains about 40K words that are classified and grouped appropriately.
Self-described as a “software-toolkit for computational literature”, RiTa library is very simple to use but has incredibly intricate and complex results. I don’t want to go on forever about it, so I’ll link you to the RiTa
homepage: https://rednoise.org/rita/index.php

To create the text generator, I had to use the Markov chain function. The Markov chain is frequently used in natural text generation through programming. Essentially, the Markov chain takes input text and analyzes the words and which other words follow them and so on. Through this analysis, the Markov chain function allows the program to randomly generate grammatically correct sentences from the input text (in this case, the emobot_words.txt file). This is achieved by calling a function known as markov.generateSentences(); .

captura-de-pantalla-2016-12-09-a-las-5-36-48-pm

captura-de-pantalla-2016-12-09-a-las-5-36-36-pm

RiTa’s reference page provided me with the accurate syntax/template codes to complete this program.

//First and foremost, I'd like to thank the creators of the RiTa.js lexicon library. Having an archive of over 40,000 words each 
//tagged with their part of speech and other words that rhyme with each other served as an incredible resource.
//They're the reason I came up with this idea of a Gothic twitterbot. I couldn't have feasibly achieved
//this goal without them. So, cheers! I'd also like to thank Dan Shiffman for his enthusiastic and comprehensive YouTube tutorials. 
//He really simplified RiTa.js for me.Last but not least owe a lot
//to my good friend, Kate Chaudoin (sophomore Art student), for introducing me to the website called Temboo which 
//enabled me to activate my twitter bot in the first place. 
// here are some links to each of the sources:
//RiTa- https://rednoise.org/rita/
// Dan Shiffman's tutorial for RiTa - https://www.youtube.com/watch?v=lIPEvh8HbGQ


//Rhea Nayyar
//rnayyar@andrew.cmu.edu
//Section C
//Final Project: "A Girl Dismissed"


import rita.*; //importing the RiTa library was significantly easier in Processing than it was in p5.js
import com.temboo.core.*; //importing the Temboo library; This enabled me to link this code to my twitterbot. 
import com.temboo.Library.Twitter.Tweets.*; //action selection for the twitter account: making original tweets

// Create a session using your Temboo account application details
TembooSession session = new TembooSession("rnayyar", "myFirstApp", "CmyUrfljnbdF53KJXDq3Wby46L7979Wq");  //configuring the Temboo account
boolean alreadyTweeted = false; //There was an issue with the bot where several tweets would spam the dashboard so I needed to solve that. This will come
//in handy soon.

RiMarkov markov; //so markov is short for markov chain. This will be better explained in the WordPress post
String line = "click to (re)generate!";
String[] files = { "emobot_words.txt" }; //I'll put the contents of this .txt file in a pastebin link. This file is what the code is
//generating tweets from.
int x = 160, y = 240;

void setup()
{
  // Run the StatusesUpdate Choreo function

  size(500, 500);

  fill(0);
  textFont(createFont("times", 16));

  // create a markov model w' n=3 from the files
  markov = new RiMarkov(2); //the minimum value of a Markov chain is 2. 
  //Or else there wouldn't be any chain in the first place.
  //when I had the value set any higher, the tweets were just full sentences
  //taken directly from the file itself rather than randomly generated text!

  markov.loadFrom(files, this); //having the markov chains be created from the emobot_words.txt file
}

void draw()
{
  int m = minute(); //Establishing the minute count
  if (m == 0 || m == 30) { //tweeting every half hour OR when mouse is clicked on the running program
    if (! alreadyTweeted) { // So I ran into a bug where the tweets would stack up, like 25 consecutive Tweets in a minute
    //so I had to make a variable that acted like a switch to only allow a single tweet at the appropriate time.
      mouseClicked();
      alreadyTweeted = true;
    }
  }
  if (m != 0 && m != 30){ //
    alreadyTweeted = false;
  }
  
  background(250);
  text(line, x, y, 400, 400); //The sentence that appears in the program is the Tweet.
}

void mouseClicked() //to be used to tweet and is called during the half-hour points
{
  if (!markov.ready()) return; 

  x = y = 50;
  String[] lines = markov.generateSentences(1); //Make 1 sentence (to keep the character count <= 140)
  line = RiTa.join(lines, " "); //Ensure the spacing between words
  if (line.length() <= 140) { //if the character count is less than or equal to 140,
    runStatusesUpdateChoreo(); //then there will be a new tweet posted! Hooray!
  }
}

//This is all information that begins the Temboo twitter session

void runStatusesUpdateChoreo() { //Getting the statuses up on the internet
  // Create the Choreo object using your Temboo session
  StatusesUpdate statusesUpdateChoreo = new StatusesUpdate(session);

  // Set inputs: I had to apply for a Twitter Oauth and be granted several access/consumer tokens and keys to
  //establish my twitter bot. Honestly, I don't necessarily understand what all of this means but I guess it's
  //protocol for all twitter bots.  
  statusesUpdateChoreo.setStatusUpdate(line);
  statusesUpdateChoreo.setAccessToken("804823521969012738-90EEFOWgIna27cGgTkpdGpz7e4vxc4a");
  statusesUpdateChoreo.setConsumerKey("DGaBwh7Nb8XMoqZdr2rbCRFIm");
  statusesUpdateChoreo.setConsumerSecret("DGHRGF0NlLawm3ysvpomMhImPHqld6bGfUwga2DBsbOzl88fzP");
  statusesUpdateChoreo.setAccessTokenSecret("qBphkOOY7asJcGgOVsO4kcmuFvjYVEOCdJbIveG5J1bbi");

  // Run the Choreo and store the results
  StatusesUpdateResultSet statusesUpdateResults = statusesUpdateChoreo.run();

  // Print results
  println(statusesUpdateResults.getResponse()); //Voila! We're done!
}


As for actually creating the bot, Temboo was my go-to source for the implementation. It provided me with many outlets to create a bot with, but Twitter was my final choice. I had to go through some hoops (well, not really… I just needed to apply for the OAuth keys and tokens and connect them with the account) to get it up and running but it works and I’m quite happy about that!
captura-de-pantalla-2016-12-09-a-las-5-36-16-pm

In the end, sometimes the bot really has a hard time making sense. They may not always be syntactically correct or have and contextual information but they’re humorous, relatable (1 out of every 5 times I suppose), and poetic. It’s as if the person who would be behind this is too overwhelmed with their thoughts to make coherent sentences sometimes. We’ve all been there.

Stay spooky, my dark, damaged friends!

-Rhea

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/12/09/rhea-nayyars-final-project-a-girl-dismissed-the-angsty-goth-twitterbot/feed/ 0
Looking Outwards 11: Mika Vainio https://courses.ideate.cmu.edu/15-104/f2016/2016/11/12/looking-outwards-11-mika-vainio/ https://courses.ideate.cmu.edu/15-104/f2016/2016/11/12/looking-outwards-11-mika-vainio/#respond Sat, 12 Nov 2016 00:20:39 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=7027 Continue reading "Looking Outwards 11: Mika Vainio"]]>

Mika Vainio is of Finnish descent but is currently based in Oslo, Norway. Since the 80’s, Vainio has been involved in the experimental sound art movement and played with the electronics to participate in the Finnish industrial and noise scene.

Vainio delves into minimal avant techno in his earlier practices. He also works under several pseudonyms such as ‘Ø’, ‘Philus’, and a duo known as Pan Sonic. Pan Sonic credits a lot of its inspiration to early industrial sound artists like Throbbing Gristle and Suicide. Vainio often remarks that their music is a cross of these two schools of music, taking the harsh and pure sounds typical of industrial techno and stretching them out into longer, subdued soundscapes reminiscent of instrumental reggae and dub.

Lots of their sounds are created using samples and an MPC2000 Sequencer. This device is now considered a “Vintage Unit”, but at the time it was responsible for the advancement of Vainio’s experimental sound practice.

On his website, I found a list of the current technology he uses during his performances and installations today:

1 MIDI keyboard (minimum of 2 octaves, 24 keys) to control his synthesizer, plus stand (with power adaptor, No USB)

with faders, 4 mono channels and 4 STEREO (!!) channels minimum, pre and post switches for fx, three range EQ and – most important! –  2 aux out-sends

  • 2 good monitor speakers
  • Mika Vainio can either use 1/4 inch (jack) and XLR for output
  • Strong, good quality PA
    Powerful subwoofers should go down to 20 Hz
    Overall range 20 Hz – 20 kHz
  • Mika Vainio will bring a case of approx. 20 kg which includes :
    Korg SX sampler/ sequencer, Lexicon FX unit, Vermona Mono Lancet synthesizer, OTO sound processing unit.

These two pieces in particular really caught my eye (ear). They’re from the early 90’s, but that’s besides the point. They’re both very experimental, and give off almost “extraterrestrial” vibes if that makes sense. There’s not much white noise, so the gaps between the sounds are very quiet… Silent almost. It’s very eerie, it almost reminds me of the stillness and curious nature of outer space itself. I love it.

http://www.mikavainio.com/

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/11/12/looking-outwards-11-mika-vainio/feed/ 0
Rnayyar: looking outwards 10; Sophie Kahn https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-looking-outwards-10-sophie-kahn/ https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-looking-outwards-10-sophie-kahn/#respond Sat, 05 Nov 2016 02:26:28 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=6688 Continue reading "Rnayyar: looking outwards 10; Sophie Kahn"]]>

I’m going to talk more about a process employed by Ms. Sophie Kahn rather than a specific project.
Sophie Kahn is a new media artist who grew up in Melbourne, Australia, and attended Goldsmith’s College in London for Fine Arts and Art History; she graduated in 2001.

Sophie has a history in photography, actually- which she finds useful in her pursuit of new media practices. Her sculptures combine Victorian era portraits/busts with 3D glitch art. With the use of the hyper-sensitive 3D laser scanner, she receives information about her subject’s face or body but with an aesthetically fascinating flaw. Due to the sensitivity of the 3D scanner, any movement is detected and registered. Therefore, the rendered subject is recorded with the movements of simple muscle twitches and even breaths that cause some sort of offset.

L:Degrade, 2012 Bronze (cast from 3D print) Life size

The results are these fascinating, almost historical sculptures that are either casted or 3D printed entirely.

Reclining Figure of a Woman, 2013 3D print (from 3D laser scan) Life size

Kahn does a spectacular job of embodying the allure and mystery of new media techniques in a classical manner which reminds viewers of ancient, excavated artworks from past eras. As someone in the School of Art here at CMU, I often find it very difficult to bridge that polarity but Sophie Kahn manages to accomplish it in an intriguing and sophisticated manner.

https://vimeo.com/58810920

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-looking-outwards-10-sophie-kahn/feed/ 0
RNAYYAR Generative Landscape https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-generative-landscape/ https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-generative-landscape/#respond Sat, 05 Nov 2016 01:17:23 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=6665 Continue reading "RNAYYAR Generative Landscape"]]>

Initially, I wanted to have a Bhutan inspired mountain-scape with Buddhist temples at the peaks. I couldn’t figure out how to establish temples at the peaks without recycling the Planting the Flag code, but I didn’t know how to tweak that function that renders the terrain in the first place so I gave up. Then I changed my idea anyways.

These are some strong and determined birds migrating to warmer climate.  They have a long way to go.

I don’t really like how this appears in-site so I’m attaching an openprocessing.org link that will take you to a full screen version of this:

https://www.openprocessing.org/sketch/388221

I highly recommend looking at the link instead!

 

sketch

/* Rhea Nayyar
rnayyar@andrew.cmu.edu
Section C
Project 10-C; Generative Landscape
*/

var terrainSpeed = 0.0003;
var terrainDetail = 0.0025;

function setup() {
    createCanvas(windowWidth, windowHeight);
    frameRate(10);
}
 
function draw() {
    background(200, 240, 255); //sky
   
 noStroke();
    fill(40, 75, 55, 100);  //rolling mountain tops
    beginShape(); 
    for (var x = 0; x < width; x++) {
        var t = (7*x * terrainDetail) + (millis() * terrainSpeed/2);
        var y = map(noise(t/2), 0,1, 0, height);
        curveVertex(x, y); 
    }
 curveVertex(width, height);
 curveVertex(0,width);
 endShape(CLOSE);



 noStroke(); //cloud front 1 (hits the floor of the canvas)
    fill(255, 245, 250, 90); 
    beginShape(); 
    for (var x = 0; x < width; x++) {
        var t = (4.5*x * terrainDetail) + (millis() * terrainSpeed/2);
        var y = map(noise(t/2), 0,1, 0, height);
        curveVertex(x, y); 
    }
 curveVertex(width, height);
 curveVertex(0,width);
 endShape(CLOSE);


    noStroke(); //cloud front 2 (hits the floor of the canvas)
    fill(250, 240, 250, 180); 
    beginShape(); 
    for (var x = 0; x < width; x++) {
        var t = (2.5*x * terrainDetail) + (millis() * terrainSpeed/2);
        var y = map(noise(t/2), 0,1, 0, height);
        curveVertex(x, y); 
    }
 curveVertex(width, height);
 curveVertex(0,width);
 endShape(CLOSE);


 fill(252, 250, 255, 140) //wispy cloud stream 1
 beginShape();
 for (var x = 0; x < width; x++) {
        var t = (x/2 * terrainDetail) + (millis() * terrainSpeed/2);
        var y = map(noise(t/2), 0,1, 0, height);
        curveVertex(x, y); 
 }
        endShape(CLOSE);

fill(232, 250, 255, 140) //wispy cloud stream 2
 beginShape();
 for (var x = 0; x < width; x+=3) {
        var t = (x * terrainDetail) + (millis() * terrainSpeed/2);
        var y = map(noise(t/2), 0,1, 0, height);
        curveVertex(x, y); 
 }
        endShape(CLOSE);


     for (var x = 0; x < width; x+=12) { //bird line
        var t = (1.5*x * terrainDetail) + (millis() * terrainSpeed/8);
        var y = map(noise(t/2), 0,1, 0, height);
        if(x%7===0){
            
        fill('Red');
        birb(x,y);
     }
    
}
    
   
}

function birb(x, y){
    fill(70);
    ellipse(x, y, 30, 10); //body
    rect(x+5, y-2, 12, 5); //tiny neck
     fill(220, 200, 0);
    triangle(x+21, y-2, x+28, y+2, x+21, y+3); //beak
    fill(70);
    ellipse(x+16, y, 11, 8); //head
    fill('MediumSlateBlue'); //eye
    ellipse(x+17, y-1, 2, 2);
    fill(85); //wing
    quad(x-3, y-3, x+10, y, x+8, y+7, x-10, y+10, 20);


}

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/11/05/rnayyar-generative-landscape/feed/ 0
RNAYYAR reflection: Mreyes- Looking Outwards 5//Sublime Moments https://courses.ideate.cmu.edu/15-104/f2016/2016/10/26/rnayyar-reflection-mreyes-looking-outwards-5sublime-moments/ https://courses.ideate.cmu.edu/15-104/f2016/2016/10/26/rnayyar-reflection-mreyes-looking-outwards-5sublime-moments/#respond Wed, 26 Oct 2016 14:03:43 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=5983 Continue reading "RNAYYAR reflection: Mreyes- Looking Outwards 5//Sublime Moments"]]>

Original link to MREYES looking outwards post

Mercedes selected an Eyal Gever 3D media exhibition called “Sublime Moments” that debuted in 2014 at Frankfurt, Germany. According to his biography, Gever served in the Israeli defense forces as a computer graphics situation simulator. His occupation paved an artistic path for him in that he eventually developed his own software to use and expand upon.
In “Sublime Moments”, Gever uses his software to create ~~moments~~ of natural and man-made occurrences such as waves in the ocean coupled with a large purple sphere being popped and torn open.

This is a comprehensive link to Gever’s general work and exhibition

With these sections of moments, Gever compiles these compositions and sends them to the world’s largest 3D printer. To recreate something so detailed in digital and physical media is really unbelievable to me.

Mercedes talks about her opinion on Gever’s work and conceptual processes below

I admire this body of pieces because, I usually find hyperrealism (in both painting and sculpture) to be impressive but, ugly. However with Gever’s work I found his subject matter interesting as well as his execution and the forms he chooses to depict. The collection of pieces is enticing to look at as the forms suggest a movement but also give hint to a bigger motion yet to come. Gever Manages to capture the ominous potential along with a beauty and serenity of natural forms in a poetic juxtaposition.

I’m inclined to agree with her because I also find hyperrealism to be impressive but also somewhat grotesque. Gever capitalises on this ‘grotesqueness’ by incorporating a glossy and intricately surreal materiality to his pieces. This results in a very contemporary rendition of
what we are already naturally familiar with.

http://www.eyalgever.com/spherepop/  <– video of the sphere puncturing which serves as the starting point for Sphere Pop the sculpture.

Sphere Pop | 2014
Waterfall | 2014
]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/10/26/rnayyar-reflection-mreyes-looking-outwards-5sublime-moments/feed/ 0
Rnayyar curve composition https://courses.ideate.cmu.edu/15-104/f2016/2016/10/15/rnayyar-curve-composition/ https://courses.ideate.cmu.edu/15-104/f2016/2016/10/15/rnayyar-curve-composition/#respond Sat, 15 Oct 2016 03:41:54 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=5634 Continue reading "Rnayyar curve composition"]]>

Uhh, so I tried to pore over all the curves available on mathworlds and kept on getting frustrated over my lack of understanding (math is, unsurprisingly, my weakest subject… especially when there are letters involved). I ended up modifying the example Epitrochoid code displayed in the deliverables section for week 7 to turn it into something completely unusual and unique compared to its original form. I named the function ‘Spanish Dancer’ because it reminds me of the wiggling, gyrating movements of fabric that are signature aspects of the revered Spanish Dance technique. My final product looks vaguely like the result of the sun reflecting light in a swimming pool, I suppose. I think that the final product was enhanced greatly by the inclusion of the ghosting effect, varying levels of opacity, and the rotation of one of the curves.

 

sketch

/* Rhea Nayyar
rnayyar@andrew.cmu.edu
Section C
Project 07-3; Curve Composition
*/

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


function draw() {
    background(20,20,20, 30); //background with the ghosting command
    
    push();
    translate(width/2 - 30, height/2 - 30); //first curve shifted
    fill(70, 10, 200, 30); //Fluorescent Indigo-ish 
    spanishDancer(); // my curve function name
    pop();

    push();
    translate(width/2, height/2); //Second Curve Shifted
    rotate(20); //Tilt!
    fill(50, 160, 220, 20); //Somewhat greenish. Like a transluscent teal.
    spanishDancer(); //Second curve function called
    pop();
 

    push();
    translate(width/2 + 30, height/2 + 30); //Third curve shifted
    fill(100, 100, 220, 60); //It's kind of like a more intense version of periwinkle? 
    spanishDancer(); //third curve function called
    pop();
    
}

function spanishDancer(a, x, y) { //my curve
    var x;
    var y;
    
    var a = 80.0; //starts off with the same parameters as that example epitrochoid function on the deliverables page
    var b = a / 2.0;
    var h = constrain(mouseY / 15.0, 0, b);
    var ph = mouseX / 20.0;
    
    
    noStroke();
    beginShape(); //but then it gets wacked out by me playing with the parameters
    for (var i = 0; i < 100; i++) {
        var t = map(i, 0, 100, 0, TWO_PI);
        
        x = (a + b) * cos(t/2) - h * cos(ph + t*2 * (a + b) / b);
        y = (a + b) * sin(t*2) - h * sin(ph + t/2 * (a + b) / b);
        vertex(x,y);

        //lots of guessing and checking led to this happy, aesthetic accident. :)
    }
    endShape(CLOSE);
 


   
}

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/10/15/rnayyar-curve-composition/feed/ 0
RNAYYAR ABSTRACT CLOCK https://courses.ideate.cmu.edu/15-104/f2016/2016/10/09/rnayyar-abstract-clock/ https://courses.ideate.cmu.edu/15-104/f2016/2016/10/09/rnayyar-abstract-clock/#respond Sun, 09 Oct 2016 00:16:10 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=5118 Continue reading "RNAYYAR ABSTRACT CLOCK"]]>

 

It took me ages to come up with an idea for this. I really didn’t want to do something that looked like an actual clock that had hands or increasing bars or whatnot, so I opted for the “digital” route…

Essentially, it’s game day and we have our blimp here making his 1 minute rounds. The score for team 1 (HOME) increases by 1 point every minute. And our lovely fangirl has her eye on a different player every hour.

Coding this wasn’t all too difficult, just really time consuming and somewhat tedious because of all the shapes. It was pretty entertaining though 🙂

sketch

/* Rhea Nayyar
rnayyar@andrew.cmu.edu
Section C
Project 06-c; abstract clock
*/

function setup() {
    createCanvas(500, 500);
    frameRate(5);
    
     background('LightPink');
}

function draw() {
   
angleMode(DEGREES);

var h = hour(); 
var x = (h%12); //enabling 12 hr clock
var m = minute();
var s = (second()*6);

 background('LightBlue'); //sky

 //blimp (sec)
    stroke('Black');
    fill('DimGrey');
    rect(s+5,58, 15, 10);
    rect(s-60, 40, 4, 3);
    fill(random(200,255));
    noStroke();
    ellipse(s-60,41,3,8);
    fill('ForestGreen');
    stroke('DarkGreen');
    quad(s-50, 30, s-40, 35, s-46, 20, s-55, 15);
    quad(s-50, 50, s-40, 50, s-46, 60, s-55, 65);
    fill('Lime');
    stroke('ForestGreen');
    ellipse(s,40, 110, 45);


//scoreBoard (minute)
 stroke('Black');
 fill(50);
 rect(10,140,480,400);
 fill('Black');
 rect( 15, 145, 470, 50);
 fill('Azure');
 textSize(35);
 textFont('Lucinda');
 text("    S C O R E   B O A R D", 38, 185);
  for(var c = 0; c < 47; c ++){
        for( var r = 0; r<45; r++){
fill(35);
ellipse(20 + c*10, 200 + r*10, 5, 5);
}
}
fill('Black');
rect(45, 250, 170, 100);
rect(290, 250, 170, 100);
fill('Yellow');
textFont('Courier');
textSize(70);
text(" " + m, 50, 320); //minute
text(" " + m-8, 330, 320); //random number that changes. I'd feel bad if the other team was stagnant :)
fill('SlateGrey');
rect(65, 360, 140, 30);
rect(315, 360, 140, 30);
fill('Yellow');
textSize(20);
textFont('Verdana');
text("T/1: HOME", 90,385);
text("T/2: AWAY", 330,385);


//fangirl
    fill('SaddleBrown');
    stroke('Black');
    quad(370,307, 427, 307, 440, 400, 360, 400);


    fill('LavenderBlush');
    noStroke();
    rect(390,360,23,40);
    fill('DarkSalmon');
    triangle(380,370, 420, 370, 400, 393);
    fill('LavenderBlush');
    ellipse(400,350,50,65);
    fill('MistyRose');
    stroke('RosyBrown');
    strokeWeight(.3);
    ellipse(400, 355, 7, 15);
    noStroke();
    ellipse(400,360,10,5);
    fill('Maroon');
    ellipse(400, 372, 10, 5);
    fill('White');
    stroke('DimGrey');
    strokeWeight(1);
    ellipse(390,345, 8, 5);
     ellipse(410,345, 8, 5);
     fill('Indigo');
     ellipse(390,345,4,4);
     ellipse(410,345,4,4);
     fill('Black');
     ellipse(386, 355, 11,2);
     ellipse(414, 355, 11,2);
      fill('SaddleBrown');
    stroke('Black');
    quad(375,310, 420, 310, 430, 340, 370, 340);
    fill('Plum');
    quad(355,400, 445, 400, 425, 500, 375,500);
    rect(350,290,20,120,4);
    rect(430,290,20,120,4);
    noStroke();
    fill('LavenderBlush');
    ellipse(355,285, 20,20);
     ellipse(440,285, 20,20);

     //Fan sign (hour)
     fill('Tomato');
     rect(340,180,130,100);
     fill('LavenderBlush');
    ellipse(360,280, 6,20);
     ellipse(435,280, 6,20);
     fill('Black');
     textFont('Impact');
     textSize(36);
     text("I LOVE \n  #" + x, 360,230);

}

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/10/09/rnayyar-abstract-clock/feed/ 0
rnayyar puppy wallpaper https://courses.ideate.cmu.edu/15-104/f2016/2016/10/01/4369/ https://courses.ideate.cmu.edu/15-104/f2016/2016/10/01/4369/#respond Sat, 01 Oct 2016 01:24:32 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=4369 Continue reading "rnayyar puppy wallpaper"]]>

sketch

//Rhea Nayyar
//rnayyar@andrew.cmu.edu
//Section C
//Project 05-C; Wall Paper





function setup() {
    createCanvas(800, 800);
    noStroke();
}

function draw() {
    background(204, 157, 204);
    for (var y = 0; y < height+20; y += 80) {
        for (var x = 0; x < width; x += 205) {
            fill('SaddleBrown'); //Longer Rows of Paw Prints
            ellipse(x+20, y, 10, 15); //Toe 1
            ellipse(x+30, y-13, 10, 15); //Toe 2
            ellipse(x+45, y-15, 10, 15); //Toe 3
            ellipse(x+55, y, 10, 15); //Toe 4
            ellipse(x+30,y+17,20,20); //Pad part 1
            ellipse(x+45,y+17,20,20); //Pad part 2
            ellipse(x+38,y+12,30,15); //Pad part 3 (connects two pads with oval)
    }

 }

 for (var y = 50; y < height-20; y += 100) {
        for (var x = 65; x < width; x += 205) {
            fill('SaddleBrown'); //Shorter Rows of Paw Prints
            ellipse(x+20, y, 10, 15);
            ellipse(x+30, y-15, 10, 15);
            ellipse(x+45, y-13, 10, 15);
            ellipse(x+55, y, 10, 15);
            ellipse(x+30,y+17,20,20);
            ellipse(x+45,y+17,20,20);
            ellipse(x+38,y+12,30,15);
           
    }

 }
 for (var y = 20; y < height+45; y += 85) {
        for (var x = 65; x < width; x += 205) { //Dog bones
             push();
            rotate(radians(2));
            fill('PapayaWhip');
            rect(x+95,y-5,45,10);
            ellipse(x+90,y-4,15,15);
            ellipse(x+91,y+6,15,15);
            ellipse(x+140,y-4,15,15);
            ellipse(x+141,y+6,15,15);
            pop();
            
            
}
}
    noLoop(); 
}

I love dogs and I miss mine dearly. I find their paw prints to be incredibly precious <3
I made a nifty graphic to commemorate the canine existence!

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/10/01/4369/feed/ 0
Rnayyar String Art https://courses.ideate.cmu.edu/15-104/f2016/2016/09/25/rnayyar-string-art/ https://courses.ideate.cmu.edu/15-104/f2016/2016/09/25/rnayyar-string-art/#respond Sun, 25 Sep 2016 02:02:38 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=3861 Continue reading "Rnayyar String Art"]]>

sketch


//Rhea Nayyar
//rnayyar@andrew.cmu.edu
//Section C
//Project 04 String Art

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

function draw() {
	background('Plum');
	var y = 4
	stroke('PowderBlue'); //tiled blue rectangles
	strokeWeight(1);
	fill('Plum');
    for (var x = 1; x < 640; x+=25){
    	rect(x,0,640,y); //across
    	rect(0,x,640,y); //vertical
    	y=y*1.777777;
    }
    
   var y = 2
    
    for (var i = 0; i < 600; i+=15) {
    	strokeWeight(1);
    	fill('Plum');
    	stroke('Lime');
    	ellipse(320,240,800/y,400/y); //concentric ellipses in the middle
    	stroke('Indigo');
    
    	line(640,0,0,y); //Purple diagonal lines from (640,0)
    	y=y*1.333333;
    }

    var y = 2
    for (var i = 0; i < 640; i+=15) {

    	stroke('DeepPink');
    	strokeWeight(1);
    	line(0,0, 640,y); //Hot pink lines from 0,0
    	
    	y=y*1.333333;
    }
    fill('Peru'); //Flower Pot
    stroke(0);
	rect(310,220,20,20);
	stroke('OliveDrab'); //Leaves and Stem
	strokeWeight(3);
	line(320,218,320,190);
	fill('OliveDrab');
	ellipse(313,200,10,5);
	ellipse(328,200,10,5);
	fill('LightPink') //Flower Center
	strokeWeight(1);
	stroke(0);
	ellipse(320,185,10,10);
	fill('PeachPuff'); //Petals
	triangle(315,185,310,180,310,190);
	triangle(325,185,330,180,330,190);
	triangle(320,180,315,175,325,175);
	triangle(322,245,328,240,325,250);

}

This took me ages. I had no idea what I was doing. I still don’t really understand. It looks cool, I guess. I like the concentric pattern in the middle. It ended up being very “Vaporwave” by accident but I like it. It’s definitely not as complex as others, unfortunately. I guess it’s almost a meditative piece, focusing on the cyclical existence of plant life. Hence the lost petal.

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/09/25/rnayyar-string-art/feed/ 0
rnayyar- Dynamic Drawing; project 3 https://courses.ideate.cmu.edu/15-104/f2016/2016/09/17/rnayyar-dynamic-drawing-project-3/ https://courses.ideate.cmu.edu/15-104/f2016/2016/09/17/rnayyar-dynamic-drawing-project-3/#respond Sat, 17 Sep 2016 02:18:04 +0000 https://courses.ideate.cmu.edu/15-104/f2016/?p=3021 Continue reading "rnayyar- Dynamic Drawing; project 3"]]>

I had a lot of issues coming up with an idea but looking at my ceiling fan for a little while helped me come to this quirky conclusion. Windmills are neat, I like them a lot, and I was inspired to create this. The mouseX position correlates to the current weather inside the canvas and the mouseY position correlates to the blade speed depending on the weather 🙂
Figuring out how to make the blades go faster took a long time. I tried to make a variable called Windspeed for the “rotate(milli()/1000);” part, and just have it as “rotate(Windspeed);” but that broke my code… and so did many other variations of that variable attempt… So I just had to manually change it with a conditional and by switching 1000 to 500 and 200 depending on the mouseY… That was fun. 
sketch

//Rhea Nayyar
// Section C
//rnayyar@andrew.cmu.edu
//Project 03-C; Dynamic Drawing

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

function draw() {
	background("SkyBlue"); //sky
   if (mouseX>=150){
     background(105); //cloudy sky
   }
   if(mouseX>=350){
     background(random(80,145)); //stormy sky
   }
  fill('YellowGreen'); //field
  rect(0,400,640,480);
  fill("OliveDrab"); //mountains
  quad(-70,400, 100,400,45,310,-30,390);
  quad(0,400,300,400,100,330,21,400);
  quad(275,400,480,400,480,310,420);
  push();
  translate(width/2,height/2);
  fill('DarkRed'); //Windmill stalk
  quad(-40,0, 30,0, 70, 200, -60,200);
  fill("DimGrey"); //disk behind windmill blades
  ellipse(0,0,50,50);
  fill(0); //door
  stroke('Yellow'); //molding
  rect(-10,150,30,50);
  fill("White"); //windmill blades
  noStroke();
   if (mouseY>=200){
     rotate(millis()/500); //mid-speed (cloudy)
   }
   if (mouseY>=420){
     rotate(millis()/100); //super-speed (stormy)
   }
  rotate(millis()/1000); //regular speed (normal)
  rotate(radians(100));
  quad(0,0,95,0,85,30,10,30);
  rotate(radians(260));
  quad(0,0,95,0,85,30,10,30);
  rotate(radians(270));
  quad(0,0,95,0,85,30,10,30);
  rotate(radians(275));
  quad(0,0,95,0,85,30,10,30);
  pop();
}

]]>
https://courses.ideate.cmu.edu/15-104/f2016/2016/09/17/rnayyar-dynamic-drawing-project-3/feed/ 0