Animação simples de composição tipográfica em processing. Fiz uso da função translate e da interação «if (keyPressed)».


Código utilizado:
float x = 0;
float y = 0;
float size = height/10;
void setup() {
size(600,600);
smooth();
background(255);
}
void draw() {
PFont title_font = createFont(“Cousine”, 32);
x = x + 0.5;
y = y + 0.5;
size = size + 10;
if (keyPressed) {
if (key == ‘t’) {
fill (0); textAlign(LEFT); textSize(20);
text(“DDR”, width -550, height -550);
textAlign(RIGHT); textSize(20);
text(“CCCR”, width -50, height -550);
fill (#E54B4B); rect (width/2, height – 110, 400, 40);
fill (0); textAlign(CENTER); textFont(title_font);
text(“Genossen Kosmonauten”, width/2, height – 100);
}
}
//«Circle»
ellipseMode(LEFT);
pushMatrix();
translate(x, y);
noFill();
stroke(#E54B4B);
circle (x, y, size);
popMatrix();
//«Vertical»
pushMatrix();
rectMode(CENTER);
translate(width/2, height/2);
fill(0);
noStroke();
rect(0, 0, 1, 120);
popMatrix();
//«Central_Circle»
ellipseMode(CENTER);
fill (#E54B4B);
noStroke();
circle (300,300, height/10);
}