Spectre

I saw the new James Bond movie this weekend and decided to do a simple visualization of the text featured in the official teaser for Spectre.

spectre

I downloaded a .SRT file with the text from the teaser and turned individual sentences into an array of strings. If the string ends with the word “Bond” or “MI6” it is displayed in the center of the canvas. Other phrases are positioned randomly and vary both in size and font. To add a little flavor to the composition, I drew a target in the center and added some bullet holes.

Circles myCircle;

String[] bondClean = {"Forensics finally released this","What is it?","Personal effects","they recovered from Skyfall","You've got a secret","Something you can't tell anyone","because you don't trust anyone"
,"I always knew death","would wear a familiar face","But not yours","I was at a meeting recently","and your name came up","I'm flattered","London is still talking about me","It wasn't MI6"
,"You're a kite dancing in a hurricane","Mr Bond","Welcome","James","It's been a long time","And finally","here we are"};
PFont myFont;
PFont gillSans;
PFont randomFont;
PImage bulletHole;

String[] fontList = PFont.list();
float offsetY = 10;
float offsetX = 10;
float offsetImageX = 20;
float offsetImageY = 40;
int j = 0;
float mySize = 32;


void setup(){
  size(600,400);

  printArray(fontList);
  myFont = createFont ("Times New Roman", 64);
  textFont(myFont);
  bulletHole = loadImage("bulletHole.gif");
  
  myCircle = new Circles(500);
  textSize(mySize);
  noLoop();
   


}

void draw(){
  background(100);
  myCircle.render();
  myCircle.update();
  bondTextVisualize();
  bulletHoles();
}


void bondTextVisualize(){
  for(int i = 0; i < bondClean.length; i++){
     if(bondClean[i].endsWith("Bond")){
        bondClean[i] = bondClean[i].toUpperCase();
        gillSans = createFont(fontList[223], 64);
        textFont(gillSans);
        fill(0,220);
        textSize(120);
        text(bondClean[i], (width - textWidth(bondClean[i]))/2, height/2);
      }
      
      else if(bondClean[i].length() > 7 && bondClean[i].endsWith("MI6")){
        bondClean[i] = bondClean[i].substring(bondClean[i].length()-3).toUpperCase();
        gillSans = createFont(fontList[223], 64);
        textFont(gillSans);
        fill(0,100);
        textSize(320);
        text(bondClean[i], 10,10,width -10,height - 10);
      } 
      else if(bondClean[i].length() > 7){
      String newText = "00" + bondClean[i].substring(2,7) + "7" + bondClean[i].substring(8);
      randomFont = createFont(fontList[round(random(500))], 64);
      textFont(randomFont);
      textSize(random(20,50));
      fill(0,random(150,230));
      text(newText, 20 + offsetX, 20 + offsetY);
        if(offsetX > width || offsetX < 0){
          offsetX = 20;
          }
          else if(offsetY > height || offsetY < 0){
          }
       }
      else{
      text(bondClean[i], 20 + offsetX, 20 + offsetY);
       }
   offsetX += random(-100,80);
   offsetY += random(-20,80);
  }
}

void bulletHoles(){
  for(int i = 0; i < 10; i++){
  image(bulletHole, 20 + offsetImageX, height - offsetImageY, 50, 50);
  offsetImageX += random(-30,80);
  offsetImageY += random(0,60);
  }
}

void mousePressed(){
  saveFrame("spectre.png");
}


 

 

Leave a Reply