12.07.2015 Views

The memoir class - The UK TeX Archive

The memoir class - The UK TeX Archive

The memoir class - The UK TeX Archive

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

D. PICTURESand [Far90]; no doubt there are more recent sources available and there is a brief reviewin [Wil04a].Figure D.5 shows two of these curves. <strong>The</strong> figure was produced by the code below.\begin{figure}\setlength{\unitlength}{1mm}\centering\begin{picture}(100,100)\thicklines % first curve\qbezier(10,50)(50,90)(50,50)\thinlines % draw lines joining control points\put(10,50){\line(1,1){40}}\put(50,90){\line(0,-1){40}}% label control points\put(10,45){\makebox(0,0)[t]{\texttt{(10,50)}}}\put(50,95){\makebox(0,0)[b]{\texttt{(50,90)}}}\put(55,50){\makebox(0,0)[l]{\texttt{(50,50)}}}\thicklines % second curve\qbezier[25](50,50)(50,10)(90,50)\thinlines % draw lines joining control points% \put(50,50){\line(0,-1){40}}% \put(50,10){\line(1,1){40}}% label control points\put(50,5){\makebox(0,0)[t]{\texttt{(50,10)}}}\put(90,55){\makebox(0,0)[b]{\texttt{(90,50)}}}\end{picture}\setlength{\unitlength}{1pt}\caption{Two Bezier curves}\label{lpicf:bez}\end{figure}<strong>The</strong> three points used to specify the position and shape of the Bezier curve are calledcontrol points. <strong>The</strong> curve starts at the first control point and is tangent to the line joining thefirst and second control points. <strong>The</strong> curve stops at the last control point and is tangent tothe line joining the last two control points.In Figure D.5 the lines joining the control points for the first curve have been drawn in.<strong>The</strong> locations of all the control points for the two curves are labeled.<strong>The</strong> second Bezier curve is the same shape as the first one, but rotated 180 degrees.<strong>The</strong> first control point of this curve is the same as the last control point of the first curve.This means that the two curves are joind at this point. <strong>The</strong> line, although it is not drawn,connecting the first two control points of the second curve is in the same direction as theline joining the last two control points of the first curve. This means that the two curvesare also tangent at the point where they join. By stringing together several Bezier curvesyou can draw quite complex curved shapes.426\qbeziermax

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!