Xastol – Plot
GENERATIVE FACES
I decided to generate some faces…or rather some “creepers” entirely out of ellipses.
INITIAL THOUGHTS
Initial sketches and thoughts.
The first prototype for the faces.
Another idea I had resulted in using these “creepers” as pixels and generating another grid like visual. However, there were some complications in how it would render out on paper and also wasn’t as charming as the previous.
PROCESS
Some action shots of the plotter. (Action Shot #1)
Action Shot #2
I ended up rendering a PDF entirely for the creeper’s lower region (i.e. – spine, vomit, etc.). This would make it easier when switching out the colors(pens) used on the plotters.
Here is the other PDF of the creeper faces.
In program shot.
First rendering.
CONCLUSION
The process for generating these creeper faces involved a lot of trial and error (specifically in the early programming stages). I initially created a grid of these creepers as my initial idea. However, I was unsatisfied with what I had, so I began to play around with the number of generated creepers and ended up making a mess of an image (see last picture thoughts). After some consulting with Golan, I ended up going back to my original idea and made some changes to the creepers to make each individual one more unique and awkward (differences in “bodies” and angles of faces).
Much different from the almost instant timing of a program, the rendering of the image using a plotter took a while. Although my particular image didn’t require a lot to plot, there were complications with getting the plotter to align evenly throughout the page. If I had the chance to go back in and make some changes, I think I would change the weight of the pens (uneven because of pressure of plotter at different points). Overall, I was satisfied with what I came up with and glad I went back to my initial idea.
CODE
//Template Provided by Golan
// Xavier Apostol (Xastol)
// 60-212 (8:30 - 11:20am & 1:30 - 4:20pm)
// xapostol@andrew.cmu.edu
// Composition For A Line Plotter (Processing)
import processing.pdf.*;
boolean bRecordingPDF;
int pdfOutputCount = 11;
void setup() {
size(1000, 1000);
bRecordingPDF = true;
strokeWeight(1);
}
void keyPressed() {
// When you press a key, it will initiate a PDF export
bRecordingPDF = true;
}
void draw() {
if (bRecordingPDF) {
background(255); // this should come BEFORE beginRecord()
beginRecord(PDF, "weird" + pdfOutputCount + ".pdf");
//--------------------------------------------------------------
//Make all drawings here.
noFill();
beginShape();
float offset = 100;
float ranX = random(100);
float ranY = random(100);
for (float x=offset; x <= width - offset/2; x+=offset) {
for (float y=offset; y <= height - offset/2; y+=offset) {
creeper_pixel(x,y, 1, offset);
}
}
endShape();
//--------------------------------------------------------------
endRecord();
bRecordingPDF = false;
pdfOutputCount++;
}
}
void creeper_pixel(float x,float y, float sz, float spacing) {
float genSz = spacing/4;
float fcOff = genSz/2;
float spineX = x;
float spineY = y;
noFill();
beginShape();
//Eyes
for (float i=0; i <= sz; i++) {
float lEyeX = sin(sz*i) + random(genSz);
float lEyeY = cos(sz*i) + random(genSz);
float rEyeX = sin(sz*i) + random(genSz);
float rEyeY = cos(sz*i) + random(genSz);
ellipse(x-fcOff,y, lEyeX,lEyeY);
ellipse(x+fcOff,y, rEyeX,rEyeY);
}
//Head
for (float j=0; j < sz; j++) {
//Face
float rotInt = 15;
float hdX = cos(sz*j) + random(genSz, 3*genSz);
float hdY = sin(sz*j) + random(genSz, 3*genSz);
spineY += (hdY/2);
pushMatrix();
translate(x,y);
rotate(radians(random(-rotInt,rotInt)));
ellipse(0,0, hdX,hdY);
popMatrix();
//Mouth
float mthX = cos(sz*j) + random(genSz);
float mthY = sin(sz*j) + random(genSz);
ellipse(x,y+fcOff, mthX,mthY);
}
//Spine(Body)
for (float s=0; s < 5; s++) {
float spineSz = random(genSz/2);
spineX += random(-8, 8);
spineY += random(genSz/3);
ellipse(spineX,spineY, spineSz,spineSz);
}
endShape();
}