Code in 2009

Tumm Mutt

25_tummmuttconcept1.png

25_tummmuttconcept2.png

25_tummmuttconcept3.png

25_tummmuttconcept4-1.png

25_tummmuttconcept5.png

25_tummmuttconcept6.png

Concept art for TummMutt, spacetime shepherd dog. Below is the Processing code:

import processing.pdf.*;

<span class="kwrd">int</span> w = 6000;
<span class="kwrd">int</span> h = 600;
<span class="kwrd">int</span> r;
<span class="kwrd">int</span> x=0;
<span class="kwrd">int</span> y=0;
<span class="kwrd">int</span> dy=0;
<span class="kwrd">int</span> prevX =0;
<span class="kwrd">int</span> prevY=0;
<span class="kwrd">int</span> prevR=0;
<span class="kwrd">int</span> origY=0;
color bk_color;
color fg_color;

<span class="kwrd">void</span> setup() {
  size(w, h);
  beginRecord(PDF, <span class="str">"/Users/shawn/Desktop/TummMuttConcept1.pdf"</span>);
  smooth();
  noLoop();
  noStroke();
} 

<span class="kwrd">void</span> draw() {
  y = <span class="kwrd">int</span>(random(h-r*2)+r*2);
  origY = y;
  fill(0x000066,10);
  beginShape();
  vertex(0,y);
  prevY=y;
  <span class="kwrd">while</span> (x &lt; w) {
    r = <span class="kwrd">int</span>(random(50)+20);
    <span class="kwrd">if</span> ((x+r)&gt;w) {
    r = w-x;
     }
     x = x+r;
     fill(0x000066,10);
     bezierVertex(prevX+prevR,prevY-prevR,x-r,y-r,x,y-r);
     fill(random(255),random(255),random(255),128);
     ellipse(x, y, r*2,r*2);
     fill(random(255),random(255),random(255),128);
     rect(x-r, y, r*2, h-y);
     prevX=x;
     prevY=y;
     prevR=r;
     dy = <span class="kwrd">int</span>(random(h/2)-h/4);
     <span class="kwrd">if</span> (((y+dy)&gt;(h-r*2))||(y+dy&lt;r*2)) {
       dy = -dy;
     }
     y = y+dy;
  }

  vertex(w,h);
  vertex(0,h);
  vertex(0,origY);
  endShape();
  endRecord();

}

 
Fluxamabob Drawbot | Fluxamabob Pyramid