Tag Info

Hot answers tagged

23

I used your question to finally try out the animate package. The "animation" is in an external file, it uses the standalone package and the markings decoration of tikz: "Animation" code \documentclass[tikz,border=3mm]{standalone} \usetikzlibrary{decorations.markings} \begin{document} \tikzset{reddot/.style={decoration={markings, mark=between positions #1 ...


21

Just a proof of concept; the flow was created with a very thick dashed line with a particular dash pattern; the illusion of movement was obtained using a different value for dash phase in even and odd slides (thanks to Jake for this suggestion that simplyfied my initial code): \documentclass{beamer} \usepackage{tikz} \def\phase{0pt} \begin{document} ...


21

Last edit: With the invaluable assistance of Paul Isambert, I wrote the ocgx package. Here is an example with ocgx package (available via CTAN and via TeXLive). Three screenshots: The code: \documentclass{beamer} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage{tikz} \usetikzlibrary{ocgx,calc} \begin{document} ...


14

Here is an animate based solution with links that act as switches: \documentclass{article} \usepackage[latin1]{inputenc} \usepackage[T1]{fontenc} \usepackage{lmodern} \usepackage{tikz} \usepackage{animate} \usepackage{hyperref} \makeatletter %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% % command to create toggle link to ...


13

Does the animate package do things with the shipout routine of TeX? The external lib replaces it -- probably in an incompatible way. Nevertheless, the following approach also works: \documentclass{article} \usepackage{pgfplots} \usepackage{animate} % Comment out the following line to see what the plot looks like. \usepgfplotslibrary{external} ...


11

You can optimize the PDF animation for size using differential bitmaps and the timeline feature of the animate package. Note however, that with every new animation frame to be shown the number of differential frames that needs to be re-displayed increases by one. This may slow down a running animation as time advances. Adobe Reader was not primarily ...


10

The easiest thing is to use the animateinline environment and then "manually" include the images, and lastly make the last image have a slow frame rate. However, I would like to show you a couple of possibilities with the animate package. Throughout this the distinction between image and frame is not enforced. Please ask if in doubt. Animation problems ...


9

\usepgfplotslibrary{external} and package animate don't work well together. \tikzexternalize moves the tikzpicture environment into an external file to be processed separately (therefore, --shell-escape must be activated) and replaces the tikzpicture environment with \includegraphics. On the first pass when no external pdf graphics are available, the boxes ...


9

This can be done using a simple variation of a progress bar, as in Progress bar for latex-beamer; I used some of my own images man1, man2, but you can use your own: \documentclass{beamer} \usetheme{CambridgeUS} \usepackage{tikz} \makeatletter \def\progressbar@progressbar{} % the progress bar \newcount\progressbar@tmpcounta% auxiliary counter ...


7

The problem is that \animategraphics uses LaTeX's \IfFileExists that uses the space as end marker of the file name. Then the result \@filef@und contains the file name including a final space. \animategraphics then removes the space via \zap@space that also kills spaces in between. The following workaround redefines \animategraphics. It uses package grffile ...


6

Character for character The usage of the xstring macros is taken from the linked question. The width of the text (in \Huge style) is saved to \mytextwidth. As \StrLen counts from 0 to, in this case, 27, \multiframe needs to animate 28 frames, which is why \mylen+1 is calculated and saved to \frames. This example uses the \multiframe macro because we can ...


6

All in one approach Read the comments whether or not you need ImageMagick and/or FFMPEG installed on your machine. \documentclass{article} \usepackage{filecontents} % create a parameterized template \begin{filecontents*}{template.tex} \documentclass[tikz,border=12pt]{standalone} \usepackage{pgfplots} \begin{document} \foreach \ind in {1,2,...,30} { ...


6

Just omit any post-scaling options, such as width or scale. Then the original size, that is the size of the first graphics of the sequence, will be used for the animation. In your case, width=1\linewidth will resize the width of the animation to the line width of the hosting document. This is the largest width I would recommend, as a larger animation would ...


6

These "player buttons" are unique to the animate package and are constructed from low-level Postscript commands. The following MWE provides an interface to the symbols, entirely extracted from animate.sty (minus some colour settings). Each of the symbols is 15pt in width. Since the commands are low-level, they produce a zero-width representation within ...


6

This disables the animateinline environment, and modifies the \multiframe loop so that it does \only<2|handout:2>{.....} with the loop counter being used in <...> so beamer does its normal stuff and makes a slide corresponding to each frame of the iteration. (only the two lines marked XXX are modified. The handout specification is needed to ...


6

The problem is that animate will put all frames in the box of the size of the first frame. You need to establish a bounding box in the TikZ picture that will encompass all frames. This has also been discussed in the animate manual on page 8: A short note on the tikzpicture environment: Unlike pspicture, the tikzpicture environment is able to determine ...


5

While loading animate, the command \pdfcatalog{/AcroForm <</Fields []/NeedAppearances true>>} is executed. Strangely, the sheer existence of the AcroForm dictionary in the PDF catalog causes Adobe Reader to prompt for saving when the document is closed, and even more strangely, yet fortunately, it does not, if there is at least one animation ...


5

The reason is loosely explained in the Bugs section of the animate doc. -Ppdf loads config.pdf during DVI to PS conversion and sets the dots-per-inch resolution (DPI) in the intermediate Postscript to the value of 8000. This is equivalent to using dvips option -D8000. The only benefit of this high resolution is related to fonts generation in case of Type-3 ...


5

The manual of animate is quite explicit about this, as stated in the comment. If you are not satisfied with the text/graphics rendering in Adobe Reader you might want to play with its display settings: go Edit->Preferences->Page Display.


5

I'm not sure to understand. Do you want something like this? I've created two new commands \texthide and \textshow \newcommand*{\texthide}[1]{\underline{\phantom{#1}}} \newcommand*{\textshow}[1]{\underline{#1}} the first to be used when you want the text to be hidden and the latter when you what the text to be shown. They have to be used as in the ...


5

animate uses JavaScript because if you want animations in PDF you need either an external program (i.e. you have to include movies) or scripting support in the viewer - and the only viewer with scripting support is Adobe Reader with JavaScript. So Lua won't help you there unless you also have a viewer with Lua support (which would make you PDFs incompatible ...


5

This error only occurs if the document is typeset with pdflatex or lualatex, while xelatex, latex+dvips+ps2pdf work smoothly. animate puts the animation frame content first into a box, using the LaTeX \savebox command. The filled box is then distilled into a PDF Form XObject using the command \pdfxform from pdfTeX. The last step fails, if the box contains ...


4

The verbatim code in the animate documentation are minimal working examples that can be compiled as they are. You cannot embed a pdf with an animation into another document. Just insert the \begin{animateinline}...\end{animateinline} stuff into your beamer document source.


4

For some reasons, animate doesn't like spaces in file names. In general they should be avoided whenever possible. What happens when you feed \animategraphics with the file name "heart animation", the package tries to includeheartanimation.pdf`, removing spaces in the name. A solution is to change the category code of the space before absorbing the second ...


4

Your first problem will be solved by putting a % after \newcommand{\makelayer}{. And I think I didn't get your second question properly. It can be done as shown in this modified code of yours. \documentclass{beamer} \usepackage[utf8]{inputenc} \usepackage{tikz} \usepackage{ifthen} \usepackage{animate} \usetheme{Warsaw} \usecolortheme{whale} ...


4

During externalization, not only the tikzpicture environment in question is processed but also the rest of the page including the \animategraphics command. The latter uses the \pdfxform primitive of pdfTeX to encapsulate animation frames into PDF XObjects, which are inserted into the externalized graphics file and contribute to the file size, but which ...


4

It seems that the {1} just after the square bracket controls the frame rate: \animategraphics[autoplay,loop,height=5cm]{1}{my_pngfiles_}{0}{22} Changing that will change the speed apparently, e.g. to 8 say: \animategraphics[autoplay,loop,height=5cm]{8}{my_pngfiles_}{0}{22}


4

animate-generated animations are implemented as PDF annotations (interactive regions), which live in a separate layer above the normal page content. They are therefore always rendered in the foreground. Everything to appear in front of animated material must itself be part of the animation: \documentclass{beamer} \usepackage{animate} \usepackage{tikz} ...


4

After redefinition of some animate macros, LaTeX produces a multipage document which can be converted to SWF using pdf2swf or to bitmapped formats using other tools, e. g. dvipng. \documentclass{article} \usepackage{animate} %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% \usepackage[active,tightpage]{preview} \makeatletter ...


4

There is a bug in storebox.sty: \AtBeginDocument{% \@ifpackageloaded{pgf}{\RequirePackage{storebox-pgf}{}}% } should be \AtBeginDocument{% \@ifpackageloaded{pgf}{\RequirePackage{storebox-pgf}}{}% } When TeX executes this piece of code, it looks for the third argument to \@ifpackageloaded and it finds \ifnum which comes just after ...



Only top voted, non community-wiki answers of a minimum length are eligible