Download MetaFun - Pragma ADE

Transcript
9
The open path is defined as:
(1cm,1cm)..(1.5cm,1.5cm)..(2cm,0cm)
The ‘double period' connector .. tells METAPOST that we want to connect the lines by a smooth
curve. If you want to connect points with straight line segments, you should use --.
Closing the path is done by connecting the first and last point, using the cycle command.
(1cm,1cm)..(1.5cm,1.5cm)..(2cm,0cm)..cycle
Feel free to use .. or -- at any point in your path.
(1cm,1cm)--(1.5cm,1.5cm)..(2cm,0cm)..cycle
This path, when drawn, looks like this:
As you can see in some of the previous examples, METAPOST is capable of drawing a smooth curve
through the three points that make up the path. We will now examine how this is done.
The six small points are the so called control points. These points pull their parent point in a
certain direction. The further away such a point is, the stronger the pull.
Each point has at most two control points. As you can see in the following graphic, the endpoints
of a non closed curve have only one control point.
Paths
Welcome to MetaPost