Skip to content

Instantly share code, notes, and snippets.

@runemadsen
Created August 20, 2021 15:55
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save runemadsen/c1d979798da6163e07be70f143fc8bcc to your computer and use it in GitHub Desktop.
Save runemadsen/c1d979798da6163e07be70f143fc8bcc to your computer and use it in GitHub Desktop.
The new Processing logo program
int u = 60;
boolean showGrid = true;
void setup() {
size(480, 480);
}
void draw() {
background(255);
if(showGrid) drawGrid();
strokeCap(SQUARE);
strokeWeight(1.5 * u);
stroke(5, 100, 255);
bezier(4 * u, 1 * u, 7 * u, 1 * u, 7 * u, 5 * u, 4 * u, 5 * u);
stroke(30, 50, 170);
line(1 * u, 6 * u, 4 * u, 2 * u);
stroke(130, 175, 255);
line(1 * u, 3 * u, 2 * u, 5 * u);
}
void drawGrid() {
strokeWeight(1);
noFill();
stroke(200);
for(int col = 0; col < 9; col++) {
line(col * u, 0, col * u, 8 * u);
}
for(int row = 0; row < 9; row++) {
line(0, row * u, 8 * u, row * u);
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment