texlive[43307] Master/texmf-dist: animate (22feb17)

commits+karl at tug.org commits+karl at tug.org
Thu Feb 23 00:04:11 CET 2017


Revision: 43307
          http://tug.org/svn/texlive?view=revision&revision=43307
Author:   karl
Date:     2017-02-23 00:04:10 +0100 (Thu, 23 Feb 2017)
Log Message:
-----------
animate (22feb17)

Modified Paths:
--------------
    trunk/Master/texmf-dist/doc/latex/animate/ChangeLog
    trunk/Master/texmf-dist/doc/latex/animate/animate.pdf
    trunk/Master/texmf-dist/source/latex/animate/animate.tex
    trunk/Master/texmf-dist/source/latex/animate/files/exp.mp
    trunk/Master/texmf-dist/source/latex/animate/files/scarab.mp
    trunk/Master/texmf-dist/tex/latex/animate/animate.sty

Modified: trunk/Master/texmf-dist/doc/latex/animate/ChangeLog
===================================================================
--- trunk/Master/texmf-dist/doc/latex/animate/ChangeLog	2017-02-22 23:03:37 UTC (rev 43306)
+++ trunk/Master/texmf-dist/doc/latex/animate/ChangeLog	2017-02-22 23:04:10 UTC (rev 43307)
@@ -1,3 +1,6 @@
+2017-02-22
+	* fix: code for repeated inclusion optimized for speed
+
 2017-02-03
 	* fix: RTL related (luaTeX)
 

Modified: trunk/Master/texmf-dist/doc/latex/animate/animate.pdf
===================================================================
(Binary files differ)

Modified: trunk/Master/texmf-dist/source/latex/animate/animate.tex
===================================================================
--- trunk/Master/texmf-dist/source/latex/animate/animate.tex	2017-02-22 23:03:37 UTC (rev 43306)
+++ trunk/Master/texmf-dist/source/latex/animate/animate.tex	2017-02-22 23:04:10 UTC (rev 43307)
@@ -20,10 +20,12 @@
 \addmediapath{files}
 \usepackage{color}
 \usepackage{textcomp}
-\usepackage{lmodern}
 \usepackage{mflogo}
 \usepackage[T1]{fontenc}
 \usepackage[utf8]{inputenc}
+%\usepackage{lmodern}
+  \usepackage[tt=false]{libertine} %override beramono (doesn't look like tt font)
+  \usepackage[libertine]{newtxmath}
 \usepackage[protrusion]{microtype}
 %\usepackage{ifpdf}
 \usepackage{parskip}
@@ -108,7 +110,7 @@
 
 %\newpage
 \section{Introduction}
-This package provides an interface to create PDFs with animated content from sets of graphics or image files, from inline graphics, such as \LaTeX-picture, PSTricks or pgf/TikZ generated pictures, or just from typeset text. Unlike standard movie/video formats, package `animate' allows for animating vector graphics. The result is roughly similar to the SWF (Flash) format, although not as space-efficient.
+This package provides an interface for creating PDFs with animated content from sets of graphics or image files, from inline graphics, such as \LaTeX-picture, PSTricks or pgf/TikZ generated pictures, or just from typeset text. Unlike standard movie/video formats, package `animate' allows for animating vector graphics. The result is roughly similar to the SWF (Flash) format, although not as space-efficient.
 
 The user interacts with the animation through optional animation controls or using the mouse like so: Pressing the mouse button over the animation widget immediately pauses a playing animation and releasing it resumes playback. Pressing the shift-key at the same time reverses the playback direction. Keeping the mouse button pressed while moving the mouse pointer off the animation widget permanently pauses playback.
 
@@ -213,7 +215,7 @@
   \animategraphics{12}{frame_}{5}{50}
 \end{verbatim}
 
-The possible file formats depend on the output driver being used. In the case of \LaTeX{}+\verb+dvips+, files with the `eps' extension are at first searched for, followed by `mps' (\MP-generated Postscript) and `ps'. With pdf\LaTeX{} and Lua\LaTeX{} the searching order is: (1)~`pdf', (2)~`mps', (3)~`png', (4)~`jpg', (5)~`jpeg', (6)~`jbig2', (7)~`jb2', (8)~`jp2'\footnotemark[1], (9)~`j2k'\footnotemark[1], (10)~`jpx'\footnotemark[1]\footnotetext[1]{Only Lua\LaTeX{} currently supports JPEG2000.} and with \XeLaTeX{} or \LaTeX{}+\verb+dvipdfmx+: (1)~`pdf', (2)~`mps', (3)~`eps', (4)~`ps', (5)~`png', (6)~`jpg', (7)~`jpeg', (8)~`bmp'. That is, files capable of storing vector graphics are found first. Make sure that all file names have \emph{lower case} extensions.
+The possible file formats depend on the output driver being used. In the case of \LaTeX{} + \verb+dvips+, files with the `eps' extension are at first searched for, followed by `mps' (\MP-generated Postscript) and `ps'. With pdf\LaTeX{} and Lua\LaTeX{} the searching order is: (1)~`pdf', (2)~`mps', (3)~`png', (4)~`jpg', (5)~`jpeg', (6)~`jbig2', (7)~`jb2', (8)~`jp2'\footnotemark[1], (9)~`j2k'\footnotemark[1], (10)~`jpx'\footnotemark[1]\footnotetext[1]{Only Lua\LaTeX{} currently supports JPEG2000.} and with \XeLaTeX{} or \LaTeX{}+\verb+dvipdfmx+: (1)~`pdf', (2)~`mps', (3)~`eps', (4)~`ps', (5)~`png', (6)~`jpg', (7)~`jpeg', (8)~`bmp'. That is, files capable of storing vector graphics are found first. Make sure that all file names have \emph{lower case} extensions.
 
 This searching procedure can be skipped thanks to the package and command option `\verb+type=<file ext>+'. It enforces the embedding of files with the given file name extension \verb+<file ext>+.
 
@@ -522,9 +524,9 @@
 \end{tabularx}
 \end{table}
 
-\clearpage
+%\clearpage
 \section{Examples}
-\subsection[Animations from sets of files, using `animategraphics' command]{Animations from sets of files, using {\tt \string\animategraphics} command}\label{sect:examples}
+\subsection{Animations from sets of files, using {\tt\textbackslash animategraphics}}\label{sect:examples}
 Animations in this section are made from graphics files that were prepared with \MP. Run `\verb+mpost --tex=latex+' on the files ending in `.mp' in the `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, Fig.~\ref{fig:taylor}, originally written by Jan Holeček~\cite{hol}, shows the exponential function $y=e^x$ and its approximation by Taylor polynomials of different degree. Below the animation, a custom button was inserted using the JavaScript programming interface and the \verb+\mediabutton+ command from the `media9' package.
@@ -679,7 +681,7 @@
 \end{document}
 \end{verbatim}
 \normalsize
-\subsection[Animating PSTricks graphics, using `animateinline' environment]{Animating PSTricks graphics, using `{\tt animateinline}' environment}
+\subsection{Animating PSTricks graphics, using `{\tt animateinline}' environment}
 Fig.~\ref{fig:torus} is an inline graphics example adapted from \cite{gilg05}.
 \small
 \begin{verbatim}

Modified: trunk/Master/texmf-dist/source/latex/animate/files/exp.mp
===================================================================
--- trunk/Master/texmf-dist/source/latex/animate/files/exp.mp	2017-02-22 23:03:37 UTC (rev 43306)
+++ trunk/Master/texmf-dist/source/latex/animate/files/exp.mp	2017-02-22 23:04:10 UTC (rev 43307)
@@ -1,5 +1,5 @@
 % Jan Holecek, Alexander Grahn
-% 2013/10/15
+% 2017/02/10
 
 filenametemplate "%j_%c.mps";
 verbatimtex
@@ -6,7 +6,10 @@
 \documentclass{article}
 \usepackage[latin1]{inputenc}
 \usepackage[T1]{fontenc}
-\usepackage{lmodern}
+%\usepackage{lmodern}
+  \usepackage{libertine}
+  \usepackage[libertine]{newtxmath}
+  \usepackage[scaled=0.83]{luximono} %override beramono (doesn't look like tt font)
 \usepackage{amsmath}
 \begin{document}
 etex

Modified: trunk/Master/texmf-dist/source/latex/animate/files/scarab.mp
===================================================================
--- trunk/Master/texmf-dist/source/latex/animate/files/scarab.mp	2017-02-22 23:03:37 UTC (rev 43306)
+++ trunk/Master/texmf-dist/source/latex/animate/files/scarab.mp	2017-02-22 23:04:10 UTC (rev 43307)
@@ -7,7 +7,10 @@
 \documentclass{article}
 \usepackage[latin1]{inputenc}
 \usepackage[T1]{fontenc}
-\usepackage{lmodern}
+%\usepackage{lmodern}
+  \usepackage{libertine}
+  \usepackage[libertine]{newtxmath}
+  \usepackage[scaled=0.83]{luximono} %override beramono (doesn't look like tt font)
 \usepackage{amsmath}
 \begin{document}
 etex

Modified: trunk/Master/texmf-dist/tex/latex/animate/animate.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/animate/animate.sty	2017-02-22 23:03:37 UTC (rev 43306)
+++ trunk/Master/texmf-dist/tex/latex/animate/animate.sty	2017-02-22 23:04:10 UTC (rev 43307)
@@ -13,7 +13,7 @@
 
 \NeedsTeXFormat{LaTeX2e}
 
-\def\@anim at version{2017/02/03}
+\def\@anim at version{2017/02/22}
 \ProvidesPackage{animate}
 [\@anim at version\space PDF animations from files and inline graphics]
 
@@ -267,22 +267,15 @@
   %#1 file name, #2 page No. (multipage files), #3 Form XObj ID
   \@anim at newkey{file:\@anim at pdfmdfivesum{#1}.#2}{#3}%
 }
-%retrieve nat. dimensions from XObjects
-\def\@anim at xobjnatwd#1{% #1 Form XObj ID
-  \@anim at getkeyval{natwidth:#1}%
-}
-\def\@anim at xobjnatht#1{% #1 Form XObj ID
-  \@anim at getkeyval{natheight:#1}%
-}
-\def\@anim at xobjnatdp#1{% #1 Form XObj ID
-  \@anim at getkeyval{natdepth:#1}%
-}
-\def\@anim at xobjnatdims#1#2#3#4{% Form XObj ID, wd, ht, dp
-  \@anim at newkey{natwidth:#1}{#2}%
-  \@anim at newkey{natheight:#1}{#3}%
-  \@anim at newkey{natdepth:#1}{#4}%
-}
 
+\def\@anim at firstofthree#1#2#3{#1}
+\def\@anim at secndofthree#1#2#3{#2}
+\def\@anim at thirdofthree#1#2#3{#3}
+%macros for recalling saved nat. dimensions
+\def\@anim at xformnatwd#1{\expandafter\@anim at firstofthree#1}
+\def\@anim at xformnatht#1{\expandafter\@anim at secndofthree#1}
+\def\@anim at xformnatdp#1{\expandafter\@anim at thirdofthree#1}
+
 %helper macro that typesets graphics file into savebox
 \ifpdf
   \def\@anim at filebox#1#2{% #1 filename, #2 page No. for multipage files
@@ -344,15 +337,14 @@
     \ifx\@anim at gropts\@empty\if at anim@multipage\message{<#4>}\fi\fi%
     \@anim at makefileknown{#3}{#4.\@anim at gropts}{\@anim@@lastxform}%
   }{% file known, re-use existing form xobject
-    \setbox\@anim at box=%
-      \hbox to \@anim at xobjnatwd{\@anim at fileknown{#3}{#4.\@anim at gropts}}{%
-        \vrule width \z@
-          height \@anim at xobjnatht{\@anim at fileknown{#3}{#4.\@anim at gropts}}
-          depth \@anim at xobjnatdp{\@anim at fileknown{#3}{#4.\@anim at gropts}}%
-          \hss%
-      }%
-    \@anim at xinline{#1}{#2}{%
-      \@anim at box}{\@anim at fileknown{#3}{#4.\@anim at gropts}}%
+    \edef\@anim at curxform{\@anim at fileknown{#3}{#4.\@anim at gropts}}%
+    \edef\@anim at curndims{\@anim at getkeyval{natdims:\@anim at curxform}}% nat. dims
+    \setbox\@anim at box=\hbox to \@anim at xformnatwd{\@anim at curndims}{%
+      \vrule width \z@
+        height \@anim at xformnatht{\@anim at curndims}
+        depth \@anim at xformnatdp{\@anim at curndims}\hss%
+    }%
+    \@anim at xinline{#1}{#2}{\@anim at box}{\@anim at curxform}%
   }%
 }
 
@@ -383,8 +375,9 @@
     %put graphics into XObject
     \@anim at xform{1}{0}{#3}%
     \xdef\@anim@@lastxform{\@anim at lastxform}%
-    \@anim at xobjnatdims{\@anim at lastxform}{%
-      \@anim at curwd}{\@anim at curht}{\@anim at curdp}%
+    \@anim at newkey{natdims:\@anim at lastxform}{%
+      {\@anim at curwd}{\@anim at curht}{\@anim at curdp}%
+    }%
   }{%
     \xdef\@anim at lastxform{#4}%
   }%



More information about the tex-live-commits mailing list