Postby tomh » Wed Jun 01, 2011 12:41 am
"A path is described using the concept of a current point. In an analogy with drawing on paper, the current point can be thought of as the location of the pen. The position of the pen can be changed, and the outline of a shape (open or closed) can be traced by dragging the pen in either straight lines or curves."
Going to use Lineto as an example.
1 start at 0,0. then lineto command to x,y - two coordinates, next lineto x2,y2 - goes from where the last line finished (x,y) to (x2,y2). Otherwise you would always be repeating an unnecessary pair of coordinates
so L 24,30 L10,10
means line from 0,0 (implicit starting point) to 24,30 and then line from 24,30 (current point) to 10,10
- the same is true for the cubic path.
"current point to (x,y) using (x1,y1) as the control point at the beginning of the curve and (x2,y2) "
so here there are 4 coordinates. The "current point" is implicit in the command.