Skip to content

Instantly share code, notes, and snippets.

@nataliefreed
Last active September 1, 2016 17:40
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 1 You must be signed in to fork a gist
  • Save nataliefreed/05d07d465692b1ccfc15 to your computer and use it in GitHub Desktop.
Save nataliefreed/05d07d465692b1ccfc15 to your computer and use it in GitHub Desktop.
draw gridlines in Processing (first way)
//draw gridlines in Processing (first way)
//this version intentionally does not use loops. It can be made much more concise with loops.
//Natalie Freed August 2014 for Art and Science of Computing
size(1000, 700);
line(0, 0, 1000, 0);
line(0, 100, 1000, 100);
line(0, 200, 1000, 200);
line(0, 300, 1000, 300);
line(0, 400, 1000, 400);
line(0, 500, 1000, 500);
line(0, 600, 1000, 600);
line(0, 0, 0, 700);
line(100, 0, 100, 700);
line(200, 0, 200, 700);
line(300, 0, 300, 700);
line(400, 0, 400, 700);
line(500, 0, 500, 700);
line(600, 0, 600, 700);
line(700, 0, 700, 700);
line(800, 0, 800, 700);
line(900, 0, 900, 700);
line(1000, 0, 1000, 700);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment