25 January 2010 View Comments

Animations in PDF using LaTeX


I am using LaTeX (started with LaTeX 2.09, followed by LaTeX 3e and now XeTeX) with a WYSIWYG LyX for everything technical and scientific (reports, articles, thesis, presentations). In the last year I changed to pdfTeX in order to obtain directly pdf file output without intermediate steps like dvi and ps, and to replace eps files from my computer with pdf files. For Windows I am using MiKTeX with TexMakerX (TexMakerX is a fork of the LaTeX IDE TexMaker and gives you an environment where you can easily create and manage LaTeX documents.) which is a great editor.

Of course that I need to include animations in my presentations (for example some simulations movies). I use all the time .avi files so here are just two methods to include them in pdf.

I saw that a lot of people included as well swf, mpeg, wmv, mpg, but in my case doesn’t work with the second method, avi worked in both cases. Adobe Acrobat Reader (version 8.1.0) doesn’t want to play this kind of movies (file unsuported). I couldn’t include gif file. So, here are the methods:

Using “movie15″ package:

[cc lang="latex"]
%include the package
\usepackage{movie15}
….
….
Click bellow to start the movie:
% we can use also: mpeg wmv mpg swf
\includemovie[poster]{5cm}{5cm}{movie.avi}
[/cc]

Using “multimedia” package:

[cc lang="latex"]
%include the packages
\usepackage{multimedia}
\usepackage{hyperref}
….
….
Click bellow to start the movie:
\movie[height=5cm,width=5cm,loop]{}{movie.avi}
[/cc]

Tags: , ,
  • I agree with this blog, this comment is very interesting and I want to visit it more frequently.
blog comments powered by Disqus