9

I have tried to embed a .flv video file into a PDF using either the package flashmovie or the package media9 together with beamer and pdfLaTeX, as described, for instance, here.

The video is shown correctly in Acrobat Reader 9.4.1 on Ubuntu. However, the reader crashes when I move on to the next slide, irrespective of the contents of that slide. The reader issues the error message (acroread:7653): Gdk-WARNING **: gdk_window_set_user_time called on non-toplevel.

Has anyone come across this problem and knows the reason/a solution?

Is the procedure described above still the recommended way of including videos into PDFs? Given that Acrobat Reader does not support flash anymore, it seems like there should be better ways.

Here is a minimal non-working example with the flashmovie package:

\RequirePackage{flashmovie} 
\documentclass{beamer}
\usepackage{flashmovie}
\begin{document}
    \begin{frame}
        \flashmovie[engine=flv-player,loop=1,width=146px,height=108px,auto=1,controlbar=0]{movie.flv} 
    \end{frame}
    \begin{frame}
    \end{frame}
\end{document}

Here is a minimal non-working example with the media9 package:

\documentclass{beamer}
\usepackage{media9}[2013/11/12]
\begin{document}
    \begin{frame}
        \includemedia[width=146px,height=108px,activate=pageopen,addresource=movie.flv,flashvars={source=movie.flv}]{alternative}{VPlayer9.swf}
    \end{frame}
    \begin{frame}
    \end{frame}
\end{document}
  • Have you tried using a different movie? Can you make a MWE? – Canageek Jan 28 '14 at 0:11
  • Adobe Reader on Linux is EOL - use a different viewer, please. – Martin Schröder Jan 28 '14 at 10:36
  • @Martin: I would gladly use any combination of a PDF viewer and LaTeX package for videos, only I have not found any solution that works. Embedding videos in PowerPoint, Impress, etc. works like a charm. Embedding videos in LaTeX beamer does not work. I don't like the situation as it is, but it happens to be a fact. Also, installing media9 is a joke. As long as things are this cumbersome, almost no one will do these things. – Max Flow Jan 28 '14 at 10:42
  • There is particular version of jw-player.swf, (don't remember where I got it from or the version number) that works much much better (smooth/robust) in 9.4.1 than any other player around. I will leave the link for a short time here, in case you want to give it a try: dl.dropboxusercontent.com/u/987775/player.swf (it is actually jw-player, but keep than name if you want to use it with flashmovie (Although media6 works a little bit better with the text flow). See here, tex.stackexchange.com/questions/67663/… – alfC Mar 17 '14 at 21:49
2

Alexander Grahn's animate package is a great fallback option that works beautifully when converting videos to sequences of images.

1

Quote from the file flashmovie.sty:

There seems to be some trouble with the latex package beamer. You can't use
the flv-player reliably with it. It is prone to crash the acrobat reader while
changing pages.

Instead, you could try the media9 package (myvideo.flv to be replaced by some file of yours):

\documentclass{beamer}
\usepackage{media9}[2013/11/12]

\begin{document}
\begin{frame}{Video}
  \includemedia[
    width=0.4\linewidth,height=0.3\linewidth,
    activate=pageopen,
    addresource=myvideo.flv,        %adjust
    flashvars={source=myvideo.flv}  %adjust
  ]{\frame{Click!}}{VPlayer9.swf}
\end{frame}

\begin{frame}{Other}
  \dots stuff
\end{frame}
\end{document}
  • Thanks for the helpful answer! I will go ahead and install media9 for my texlive on Ubuntu (which appears to be cumbersome). – Max Flow Jan 28 '14 at 10:38
  • 1
    Note that you need at least media9 version 0.34 (2013/11/12). – AlexG Jan 28 '14 at 10:43
  • @Max Otherwise you could try downloading VPlayer9.swf into your current directory and use an older version of media9.sty – AlexG Jan 28 '14 at 10:51
  • Did do that. Unfortunately, I need to install some packages on which media9.sty depends, e.g. expl3.sty. This wasn't so bad if these packages were included in any Ubuntu package but I am afraid they are not. – Max Flow Jan 28 '14 at 10:56
  • What about installing the current TUG version TeXLive-2013. For Ubuntu, it is described here: help.ubuntu.com/community/LaTeX#From_the_TeX_Users_Group – AlexG Jan 28 '14 at 11:00

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.