[Latex][beamer]PGF and TiKz中演示文字沿路径移动的动画

来源:互联网 发布:淘宝热销商品 编辑:程序博客网 时间:2024/05/21 09:49

[Latex][beamer]PGF and TiKz中演示文字沿路径移动的动画,就以beamer为例:

\documentclass{beamer}%====================================================\input{../setup/preamble.tex}  \input{../setup/tikzall.tex} %包含所有的tikz包%====================================================\begin{document}%====================================================\begin{frame}%演示文字沿路径移动的动画\begin{animateinline}[autoplay,loop]{2}  %总共生成6帧画面,以每秒2帧的速度自动播放    \multiframe{6}{Rpos=1+-0.2}{%Rpos=1,0.8,...,0.0\tikz[allow upside down]{%\useasboundingbox[draw] (-1cm,-1cm) rectangle(4cm,4cm);\draw[name path=curveone] (0,0) .. controls +(right:3.5cm) and +(right:3.5cm) .. (0,3)\foreach \p in {0,0.2,0.4,0.6,0.8,1} {node[sloped,above,pos=\p]{\p}};\draw[name path=curveone] (0,0) .. controls +(right:3.5cm) and +(right:3.5cm) .. (0,3)node[sloped,below,pos=\Rpos]{$\Rpos$};}%}%\end{animateinline}\end{frame}%====================================================\end{document} 


效果是图如下:


原创粉丝点击