6 LINES

This chapter will concentrate on lines and how they are represented though code. You'll also look at how lines can represent more multidimensional space, such as shapes and volume.

It's all about points

Before you can understand a line, you need to move back one dimension and take a look at points. Here is arguably the simplest graphic program you can write in any language (see Figure 6-1):

point(50, 50);
image

Figure 6-1. Single-point sketch

I mentioned before in the book that a point really has no dimension. Wikipedia says of points: "A point in Euclidean geometry has no size, orientation, or any other feature except position." Thus, ...

Get Processing Creative Coding and Computational Art now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.