summaryrefslogtreecommitdiff
path: root/Master/texmf-dist/doc/latex/animate
diff options
context:
space:
mode:
authorNorbert Preining <preining@logic.at>2007-11-23 19:43:31 +0000
committerNorbert Preining <preining@logic.at>2007-11-23 19:43:31 +0000
commit103fa01eacdf470af9d47acbbd0f8cd3add32dcf (patch)
tree33942937250861aee01dd534c1ca79669cfa726c /Master/texmf-dist/doc/latex/animate
parentfb0a76e55e2bbb6ff31506cdb4fd9e3f63b9f665 (diff)
animate update 07-11-23
git-svn-id: svn://tug.org/texlive/trunk@5570 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist/doc/latex/animate')
-rw-r--r--Master/texmf-dist/doc/latex/animate/README2
-rw-r--r--Master/texmf-dist/doc/latex/animate/doc/animate.pdfbin1321543 -> 1308016 bytes
-rw-r--r--Master/texmf-dist/doc/latex/animate/doc/animate.tex109
-rw-r--r--Master/texmf-dist/doc/latex/animate/doc/files/scarab.mp20
4 files changed, 84 insertions, 47 deletions
diff --git a/Master/texmf-dist/doc/latex/animate/README b/Master/texmf-dist/doc/latex/animate/README
index e3cd6ac0081..1af31cea478 100644
--- a/Master/texmf-dist/doc/latex/animate/README
+++ b/Master/texmf-dist/doc/latex/animate/README
@@ -77,7 +77,7 @@ Usage:
Requirements:
- pdfeTeX, version >= 1.20
+ pdfTeX, version >= 1.20
Ghostscript, version >= 8.31 or Adobe Distiller
Adobe Reader, version >= 6
diff --git a/Master/texmf-dist/doc/latex/animate/doc/animate.pdf b/Master/texmf-dist/doc/latex/animate/doc/animate.pdf
index c0dd20c1155..ad0fe39cea0 100644
--- a/Master/texmf-dist/doc/latex/animate/doc/animate.pdf
+++ b/Master/texmf-dist/doc/latex/animate/doc/animate.pdf
Binary files differ
diff --git a/Master/texmf-dist/doc/latex/animate/doc/animate.tex b/Master/texmf-dist/doc/latex/animate/doc/animate.tex
index 0477da2d1ad..794d4a5faa7 100644
--- a/Master/texmf-dist/doc/latex/animate/doc/animate.tex
+++ b/Master/texmf-dist/doc/latex/animate/doc/animate.tex
@@ -73,9 +73,9 @@ The `animate' package makes use of Optional Content Groups (OCG), also known as
\section{Requirements}
\begin{trivlist}
-\item pdf$\varepsilon$\TeX{}, version $\ge1.20$ for direct PDF output
+\item pdf\TeX{}, version $\ge1.20$ for direct PDF output
\item Ghostscript, version $\ge8.31$ or Adobe Distiller for PS to PDF conversion
-\item Adobe Reader, version $\ge6$
+\item Adobe Reader, version $\ge6$, but not $8.0$ and $8.1$
\end{trivlist}
\section{Installation}
@@ -126,7 +126,7 @@ and the environment
While \verb+\animategraphics+ can be used to assemble animations from sets of existing graphics files, the environment `\verb+animateinline+' is meant to create the animation from the typeset material it encloses. This material can be pictures drawn within the \LaTeX{} `\verb+picture+' environment or using the advanced capabilities of PSTricks or pgf/TikZ. Even ordinary textual material may be animated in this way. The parameter \verb+<frame rate>+ specifies the number of frames per second of the animation.
-By default, the animation is built frame by frame in the order of inclusion of the embedded material. However, extended control of the order of appearance, superposition and repetition of the material is available through the `\verb+timeline+' option (see below).
+By default, the animation is built frame by frame in the order of inclusion of the embedded material. However, extended control of the order of appearance, superposition and repetition of the material is available through the `\verb+timeline+' option (see Section~\ref{sect:timeline}).
The command \verb+\newframe+ terminates a frame and starts the next one. It can be used inside the `\verb+animateinline+' environment only. There is a starred variant, \verb+\newframe*+. If placed after a particular frame it causes the animation to pause at that frame. The animation continues normally after clicking it again. Both \verb+\newframe+ variants take an optional argument that allows to change the frame rate in the middle of an animation.
@@ -136,7 +136,9 @@ There is no file name extension to be specified as a parameter. The possible fil
For example, given the sequence `frame\_5.png' through `frame\_19.png' from a possibly larger set that shall be used to build the animation. Then, {\tt <file base\-name>} would be specified as `\verb+frame_+', \verb+<first>+ as `\verb+5+' and \verb+<last>+ as `\verb+19+'.
+\section{Command options}
The following options to \verb+\animategraphics+ and `\verb+animateinline+' have been provided:
+\subsection{Basic options}
\begin{verbatim}
poster[=first | none | last]
\end{verbatim}
@@ -191,7 +193,7 @@ Changes the control button height to \verb+<size>+, which must be a valid \TeX{}
buttonbg=<colour>
buttonfg=<colour>
\end{verbatim}
-By default, control button widgets are drawn with black strokes on transparent background. The background can be turned into a solid colour by the first option, while the second option specifies the stroke colour. The parameter \verb+<colour>+ is an array of colon-(`\verb+:+')-separated numbers in the range from 0.0 to 1.0. The number of array elements determines the colour model in which the colour is defined: (1) gray value, (3) RGB, (4) CMYK. For example, `\verb+1+', `\verb+1:0.5:0.2+' and `\verb+0.5:0.3:0.7:0.1+' are valid colour specifications.
+By default, control button widgets are drawn with black strokes on transparent background. The background can be turned into a solid colour by the first option, while the second option specifies the stroke colour. The parameter \verb+<colour>+ is an array of colon-(\verb+:+)-separated numbers in the range from 0.0 to 1.0. The number of array elements determines the colour model in which the colour is defined: (1) gray value, (3) RGB, (4) CMYK. For example, `\verb+1+', `\verb+1:0.5:0.2+' and `\verb+0.5:0.3:0.7:0.1+' are valid colour specifications.
\begin{verbatim}
draft
final
@@ -205,30 +207,33 @@ end={<end text>}
\begin{verbatim}
begin={\begin{pspicture}(...)(...)}, end={\end{pspicture}}
\end{verbatim}
+
+\subsection{The `{\tt timeline}' option}\label{sect:timeline}
\begin{verbatim}
timeline=<timeline file>
\end{verbatim}
-\verb+<timeline file>+ is a plain text file whose contents determines the order of appearance of the embedded material during the animation. In addition, it allows to freely reorder, repeat and overlay the material at any point of the animation. This may greatly reduce the file size of the resulting PDF, as objects that do not change between several or all frames, such as coordinate axes or labels, can be embedded once and reused in other frames of the animation.
+\verb+<timeline file>+ is a plain text file whose contents determines the order of appearance of the embedded material during the animation. In addition, it allows to freely reorder, repeat and overlay the material at any point of the animation. This may greatly reduce the file size of the resulting PDF, as objects that do not change between several or all frames, such as coordinate axes or labels, can be embedded once and re-used in other frames of the animation.
If a timeline is associated with the animation, the graphics files or inline graphics embedded by \verb+\animategraphics+ and `\verb+animateinline+' no longer represent the actual frames of the animation. Rather, they are a collection of \emph{transparencies} that can be played with at will. In order to identify the transparencies within the timeline file, they are numbered in the order of their inclusion, starting at zero.
-Each line of the timeline file that is not blank and which does not begin with a comment (`\verb+%+') specifies \emph{one} frame of the animation. There may be more transparencies than animation frames and vice-versa. A frame specification consists of three, colon-(`\verb+:+')-separated fields:
+Each line of the timeline file that is not blank and which does not begin with a comment (`\verb+%+') specifies \emph{one} frame of the animation. There may be more transparencies than animation frames and vice-versa. A frame specification consists of three, colon-(\verb+:+)-separated fields:
\begin{verbatim}
[*]:[<frame rate>]:[<frame content>]
\end{verbatim}
While any field may be left blank, the colons are mandatory.
-An asterisk (`\verb+*+') in the leftmost field causes the animation to pause at that frame, very much like a \verb+\newframe*+ would do; a number in the second field changes the frame rate of the animation section that follows. (In connexion with the `\verb+timeline+' option the asterisk extension and the optional \verb+<frame rate>+ argument of \verb+\newframe+ cease to make sense and will be tacitly ignored, if present.) The third field \verb+<frame content>+ is a comma-separated list of \emph{transparency specifications} that determines the content of the frame. A single transparency specification obeys the syntax
+An asterisk (`\verb+*+') in the leftmost field causes the animation to pause at that frame, very much like a \verb+\newframe*+ would do; a number in the second field changes the frame rate of the animation section that follows. (In connexion with the `\verb+timeline+' option the asterisk extension and the optional \verb+<frame rate>+ argument of \verb+\newframe+ cease to make sense and will be tacitly ignored, if present.) The third field \verb+<frame content>+ is a comma-separated list of \emph{transparency specifications} that determines the content of the frame. A \emph{single} transparency specification obeys the syntax
\begin{verbatim}
<transparency ID>[x<number of frames>]
\end{verbatim}
where \verb+<transparency ID>+ is an integer number that identifies the transparency to be drawn into the current animation frame. As pointed out above, the transparencies are consecutively numbered in the order of their inclusion, starting at zero. The optional postfix `\verb+x<number of frames>+' specifies the number of consecutive frames the transparency is to appear within. If omitted, a postfix of `\verb+x1+' is assumed, which causes the transparency to be shown in the current frame only. Obviously, \verb+<number of frames>+ must be a non-negative integer number. The meaning of postfix `\verb+x0+' is special; it causes the transparency to be shown in all frames, starting with the current one, until the end of the animation.
-Note that the order in which transparency specifications appear in the timeline file determines their depth level. The animation may be thought of as a pile of transparencies. Transparencies are always put on top of that pile, possibly overdrawing objects that are on previously deposited transparencies. Once on the pile, each transparency remains at its place for the specified number of frames and is removed afterwards. That is, for a transparency to appear always on top it must be put to the rightmost end of each line in the timeline file.
+Note that the order in which transparency specifications appear in the timeline file determines their \emph{depth} level. If a frame is composed of more than one transparency, transparency specifications on the left of the input line are closer to the background and will be overprinted by those on the right which are closer to the foreground. That is, the depth \emph{de}creases from left to right within \verb+<frame content>+. Also, if there are transparency specifications which span several frames (using postfix `\verb+x<number of frames>+'), they will be overprinted by transparency specifications that appear on subsequent lines in the timeline file. That is, the depth decreases in top-down direction within the timeline file.
+%The animation may be thought of as a pile of transparencies. Transparencies are always put on top of that pile, possibly overdrawing objects that are on previously deposited transparencies. Once on the pile, each transparency remains at its place for the specified number of frames and is removed afterwards. That is, for a transparency to appear always on top it must be put to the rightmost end of each line in the timeline file.
Consider the two timelines
\begin{verbatim}
- ::1,0 % zeroth transparency always on top
+ ::1,0 % zeroth transparency always in the foreground
::2,0
::3,0
::4,0
@@ -236,17 +241,35 @@ Consider the two timelines
\end{verbatim}
and
\begin{verbatim}
- ::0x0,1 % zeroth transparency in the lowest level
+ ::0x0,1 % zeroth transparency put to the background
::2
::3
::4
...
\end{verbatim}
-In the first example, transparency No. `0' appears in the uppermost depth level throughout the animation; it will never be obscured by other transparencies' content. In the second example it is put on the lowest level (because it is the first transparency specification in the file) and stays there for the rest of the animation.
+In the first example, transparency No. 0 appears in the foreground throughout the animation; it will never be obscured by other transparencies' content. In the second example it is put to the background, because it is the first transparency specification in the file, and stays there for the rest of the animation.
+
+\emph{Grouping objects into layers using `{\tt;}'}
+
+This stack-like concept of animations, where transparencies are always put on top such that they overprint the content of previously deposited transparencies, can be inconvenient in certain situations. For example, it might be desirable to allow for changing the background image in the middle of an animation without affecting objects that are located in the foreground. For this purpose, transparency specifications can be grouped into \emph{layers} using the semicolon (\verb+;+) as a separator instead of the comma. This is best illustrated by an example:
+\begin{verbatim}
+ ::0x49;2x0,3x0
+ :: ;4x0,5x0
+ :: ;6x0,7x0
+ ...
+ :: ;98x0,99x0
+ ::1x0;100x0,101x0
+ :: ;102x0,103x0
+ :: ;104x0,105x0
+ ...
+\end{verbatim}
+In this timeline, the transparencies are grouped into two layers. One is reserved for the background images, transparencies No. 0 \& 1, that shall be exchanged after 49 frames, and another one for the foreground objects that are successively added to the scene. As can be seen in this example, layers need not be explicitly populated. The leading semicolons just ensure the proper relationship between transparencies and animation layers. Without setting up two layers, the foreground objects on transparencies 2 through 99 that have been added during the first 49 frames would be overprinted by the new background image, transparency 1, from frame 50 onwards.
+
+See the second animation in Section~\ref{sect:examples} for a working example that makes use of the timeline and the layer concept.
\section{Examples}
-\subsection[Animations from sets of files, using `animategraphics' command]{Animations from sets of files, using {\tt \string\animategraphics} command}
-Animations in this section are made from graphics files that were prepared with \MP. Run `\verb+mpost+' on the files ending in `\verb+.mp+' in the `\verb+doc/files+' directory to generate the graphics files. Both examples make use of the `\verb+timeline+' option to reduce the resulting PDF file size.
+\subsection[Animations from sets of files, using `animategraphics' command]{Animations from sets of files, using {\tt \string\animategraphics} command}\label{sect:examples}
+Animations in this section are made from graphics files that were prepared with \MP. Run `\verb+mpost+' on the files ending in `.mp' in the `doc/files' directory to generate the graphics files. Both examples make use of the `\verb+timeline+' option to reduce the resulting PDF file size.
The first example, originally written by Jan Hole\v{c}ek~\cite{hol}, shows the exponential function $y=e^x$ and its approximation by Taylor polynomials of different degree.
@@ -268,7 +291,7 @@ The first example, originally written by Jan Hole\v{c}ek~\cite{hol}, shows the e
\end{document}
\end{verbatim}
\normalsize
-Contents of file `\verb+timeline.txt+':
+Contents of file `timeline.txt':
\small
\begin{verbatim}
::0x0 % coordinate system & y=e^x, repeated until last frame
@@ -287,7 +310,7 @@ Contents of file `\verb+timeline.txt+':
\animategraphics[controls,loop,timeline=timeline.txt]{4}{exp_}{0}{8}
\end{center}
-The second, somewhat more complex example animates the geometric construction of a scarabaeus. It is adapted from Maxime Chupin's original \MP{} source file \cite{chupin}. The present version separates stationary from moving parts of the drawing and saves them into different files. A total of 153 files, \verb+scarab_0.mps+ through \verb+scarab_152.mps+, is written out by running `\verb+mpost+' on the source file `\verb+scarab.mp+'. Files 0 through 100 contain the moving construction lines and the growing scarabaeus. Files 101 through 151 contain the gray lines which represent intermediate stages of the construction. The last file, No. 152, contains the coordinate axes, two stationary construction lines and the labels which do not move. Everything is overlaid by means of a timeline file that is written on-the-fly during the \LaTeX{} run to produce an animation of 101 individual frames.
+The second, somewhat more complex example animates the geometric construction of a scarabaeus. In addition to the use of a timeline, it introduces the layer concept. This example is adapted from Maxime Chupin's original \MP{} source file \cite{chupin}. The present version separates stationary from moving parts of the drawing and saves them into different files. A total of 254 files, scarab\_0.mps through scarab\_253.mps, is written out by running `\verb+mpost+' on the source file `scarab.mp'. Files 0 through 100 contain the red line segments that make up the growing scarabaeus. Files 101 through 201 contain the moving construction lines and files 202 through 252 contain the gray lines which represent intermediate stages of the construction. The last file, No. 253, contains the coordinate axes, two stationary construction lines and the labels which do not move. A timeline file is written on-the-fly during the \LaTeX{} run. It arranges the animation into three layers, forcing the gray lines into the background, the coordinate axes into the intermediate layer and the scarabaeus along with the moving construction lines into the foreground. The final animation consists of 101 individual frames.
\small
\begin{verbatim}
\documentclass{article}
@@ -297,8 +320,10 @@ The second, somewhat more complex example animates the geometric construction of
\newcounter{scarab}
\setcounter{scarab}{0}
+\newcounter{blueline}
+\setcounter{blueline}{101}
\newcounter{grayline}
-\setcounter{grayline}{101}
+\setcounter{grayline}{202}
%write timeline file
\newwrite\TimeLineFile
@@ -306,12 +331,15 @@ The second, somewhat more complex example animates the geometric construction of
\whiledo{\thescarab<101}{
\ifthenelse{\intcalcMod{\thescarab}{2}=0}{
%a gray line is added to every 2nd frame
- \immediate\write\TimeLineFile{::\thegrayline x0,152,\thescarab}
+ \immediate\write\TimeLineFile{%
+ ::\thegrayline x0;253;\thescarab x0,\theblueline}
\stepcounter{grayline}
}{
- \immediate\write\TimeLineFile{::152,\thescarab}
+ \immediate\write\TimeLineFile{%
+ ::;253;\thescarab x0,\theblueline}
}
\stepcounter{scarab}
+ \stepcounter{blueline}
}
\immediate\closeout\TimeLineFile
@@ -321,25 +349,28 @@ The second, somewhat more complex example animates the geometric construction of
width=0.8\linewidth,
controls, loop,
timeline=\jobname.tln
- ]{12}{scarab_}{0}{152}
+ ]{12}{scarab_}{0}{253}
\end{center}
\end{document}
\end{verbatim}
\newcounter{scarab}
\setcounter{scarab}{0}
+\newcounter{blueline}
+\setcounter{blueline}{101}
\newcounter{grayline}
-\setcounter{grayline}{101}
+\setcounter{grayline}{202}
\newwrite\TimeLineFile
\immediate\openout\TimeLineFile\jobname.tln
\whiledo{\thescarab<101}{
- \ifthenelse{\intcalcMod{\thescarab}{2}=0}{%
- \immediate\write\TimeLineFile{::\thegrayline x0,152,\thescarab}
+ \ifthenelse{\intcalcMod{\thescarab}{2}=0}{
+ \immediate\write\TimeLineFile{::\thegrayline x0;253;\thescarab x0,\theblueline}
\stepcounter{grayline}
}{
- \immediate\write\TimeLineFile{::152,\thescarab}
+ \immediate\write\TimeLineFile{::;253;\thescarab x0,\theblueline}
}
\stepcounter{scarab}
+ \stepcounter{blueline}
}
\immediate\closeout\TimeLineFile
@@ -349,7 +380,7 @@ The second, somewhat more complex example animates the geometric construction of
controls,
loop,
timeline=\jobname.tln
- ]{12}{scarab_}{0}{152}
+ ]{12}{scarab_}{0}{253}
\end{center}
\normalsize
@@ -444,21 +475,21 @@ This is an inline graphics example adapted from \cite{gilg05}.
\section{Bugs}\label{sect:bugs}
\begin{itemize}
- \item The command {\tt\string\multido} and its relatives from package `multido' do not work if the loop body contains {\tt\string\newframe}. Use {\tt\string\whiledo} from package `if\/then' instead. (There is no need to load `if\/then' explicitly; it has already been loaded by `animate'.) A counter must be declared to keep track of the number of iterations. Further variables that take fixed point decimals to be used within the loop body can be defined and incremented by means of the commands \verb+\FPset+ and \verb+\FPadd+ from package `{\tt fp}'. For example:
+ \item The command {\tt\string\multido} and its relatives from package `multido' do not work if the loop body contains {\tt\string\newframe}. Use {\tt\string\whiledo} from package `if\/then' instead. (There is no need to load `if\/then' explicitly; it has already been loaded by `animate'.) A counter must be declared to keep track of the number of iterations. Further variables that take fixed point decimals to be used within the loop body can be defined and incremented by means of the commands \verb+\FPset+ and \verb+\FPeval+ from package `{\tt fp}'. For example:
\small
\begin{verbatim}
-% declare loop counter
-\newcounter{iter}%
+
+\newcounter{iter} % declare loop counter
+
+\FPset{nInit}{1.0}% initial value of variable `n'
+\FPset{nIncr}{0.5}% increment of `n'
\begin{animateinline}{12}
- %initialize loop counter
+ %initialize loop counter and `n'
\setcounter{iter}{0}%
- %define some variable, e. g. `\somevar'
- \FPset{\somevar}{1.0}%
- %make copy `\varcopy' of `\somevar' with global scope
- \xdef\varcopy{\somevar}%
+ \FPset{n}{nInit}%
...
- ... create first frame using \somevar(=1.0)
+ ... create first frame using `\n' (Mind the backslash!)
... (\multido _can_ be used here!)
...
\whiledo{\theiter<50}{% another 50 frames
@@ -466,12 +497,10 @@ This is an inline graphics example adapted from \cite{gilg05}.
\newframe%
%increment loop counter by 1
\stepcounter{iter}%
- %increment \somevar by, e. g., 0.5
- \FPadd{\somevar}{\varcopy}{0.5}%
- %refresh the copy
- \xdef\varcopy{\somevar}%
+ %calculate new value of `n'
+ \FPeval{n}{nInit+nIncr*\theiter}%
...
- ... create frame using \somevar
+ ... create frame using `\n'
... (\multido _can_ be used here!)
...
}
@@ -481,9 +510,9 @@ This is an inline graphics example adapted from \cite{gilg05}.
\item The maximum frame rate that can actually be achieved largely depends on the complexity of the graphics and on the available hardware.
- \item The Adobe Reader setting `Use page cache' (menu `Preferences'$\rightarrow$`Startup') should be \emph{dis}abled.
+ \item The Adobe Reader setting `Use page cache' (menu `Edit' $\rightarrow$ `Preferences' $\rightarrow$ `Startup') should be \emph{dis}abled.
- \item The \verb+dvips+ option `\verb+-Ppdf+' should be avoided entirely or followed by something like `\verb+-X 2400 -Y 2400+' on the command line in order to set a sensible DVI resolution. In times of Type-1 fonts, this does \emph{not} degrade the output quality! The configuration file `\verb+config.pdf+' loaded by option `\verb+-Ppdf+' specifies an excessively high DVI resolution that will be passed on to the final PDF. Eventually, Adobe Reader gets confused and will not display the frames within the animation widget.
+ \item The \verb+dvips+ option `\verb+-Ppdf+' should be avoided entirely or followed by something like `\verb+-X 2400 -Y 2400+' on the command line in order to set a sensible DVI resolution. In times of Type-1 fonts, this does \emph{not} degrade the output quality! The configuration file `config.pdf' loaded by option `\verb+-Ppdf+' specifies an excessively high DVI resolution that will be passed on to the final PDF. Eventually, Adobe Reader gets confused and will not display the frames within the animation widget.
\item Animations do not work if the PDF has been produced with Ghostscript versions older than 8.31. This applies to all versions of ESP Ghostscript that comes with many Linux distributions.
diff --git a/Master/texmf-dist/doc/latex/animate/doc/files/scarab.mp b/Master/texmf-dist/doc/latex/animate/doc/files/scarab.mp
index 8a74b530cc0..0d4dcb69039 100644
--- a/Master/texmf-dist/doc/latex/animate/doc/files/scarab.mp
+++ b/Master/texmf-dist/doc/latex/animate/doc/files/scarab.mp
@@ -8,7 +8,6 @@ verbatimtex
\documentclass{article}
\usepackage[latin1]{inputenc}
\usepackage{amsmath}
-%\usepackage[mdugm]{mathdesign}
\begin{document}
etex
@@ -24,7 +23,7 @@ vardef proj(expr P,M,N)=
enddef;
path dr,cercle,drb,scara;
-pair A,B,C,D,Q,T,O',P,O,M,M',N;
+pair A,B,C,D,Q,T,O',P,O,M,N;
O:=(0,0);
O':=(-u/3,0);
A:=(u/sqrt(2),u/sqrt(2)) shifted O' ;
@@ -40,8 +39,9 @@ for i:=0 upto 100:
P:=A;
Q:=O';
M:=proj(O,P,Q);
- scara:=M;
+ scara:=M;
else:
+ scara:=M;
for j:=1 upto 4:
k:=4*(i-1)+j;
if (k<200) or (k=200):
@@ -72,7 +72,15 @@ for i:=0 upto 100:
scara:=scara--M;
endfor;
fi;
- beginfig(i) %scarabaeus
+ beginfig(i) %red scarabaeus segments
+ setbounds currentpicture to
+ (u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
+ pickup pencircle scaled 1pt;
+ draw scara withcolor red;
+ clip currentpicture to
+ (u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
+ endfig;
+ beginfig(i+101) %moving construction lines and labels
setbounds currentpicture to
(u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
draw 12[P,Q]--12[Q,P] dashed evenly;
@@ -89,7 +97,7 @@ for i:=0 upto 100:
(u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
endfig;
if (i/2.-floor(i/2.))=0: %gray lines every second image
- beginfig(i/2+101)
+ beginfig(i/2+202)
setbounds currentpicture to
(u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
draw P--Q withcolor 0.8 white;
@@ -100,7 +108,7 @@ for i:=0 upto 100:
endfor;
%coordinate axes and stationary stuff
-beginfig(152);
+beginfig(253);
setbounds currentpicture to
(u,1.2u)--(u,-1.2u)--(-1.5u,-1.2u)--(-1.5u,1.2u)--cycle;
path ida,mida;