Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

On this frame, there are 3 swf animations starting once the slide opens. I would like to prevent them from automatically looping. I tried a few options without any success, such as endat=frame:10 or repeat=0.

This behaviour seems to be specific to swf files. I was using mp4 before, which didn't restart automatically. Unfortunately, having three animations on that page caused Adobe Reader to be extremely unstable, which is why I converted the file to swf.

Here is the code:

\frame{
\frametitle{Example 2}
Double cantilever beam
\vfill
\begin{columns}[l]
   \column{0.33\textwidth}
     \includemovie[autoplay,mouse]{1.\textwidth}{5em}{Pics/Cubic_D_Struct_AnisoShear.swf}
     \small{discrete pre-crack}\\
     \small{cubic function} 
   \column{0.33\textwidth}
     \includemovie[autoplay,mouse]{1.\textwidth}{5em}{Pics/Quad_D_Struct_AnisoShear.swf}
     \small{discrete precrack} \\
     \small{quadratic function} 
   \column{0.33\textwidth}
     \includemovie[autoplay,mouse]{1.\textwidth}{5em}{Pics/Cubic_Struct_AnisoShear.swf}
     \small{modelled pre-crack} \\
     \small{cubic function} 
\end{columns}
\vfill
} %%%
share|improve this question
    
I have no experience on the topic, but could it be related to the fact that only the first is an swf while the other two are mp4? –  Federico Mar 22 '13 at 15:34
    
You are right about that, I made a mistake. If all three are swf, they all restart automatically. I guess a more accurate question would be: "how to prevent a swf file to automatically restart with \includemovie. –  Julot Mar 22 '13 at 15:50
    
I edited the question to reflect your comment. –  Julot Mar 22 '13 at 16:23
    
With package media9 replacing movie15, there is no need for conversion of MP4 to SWF. –  AlexG Apr 25 '13 at 10:35
    
@AlexG Please consider posting an answer here to get the question off the unanswered list :-) –  Joseph Wright Aug 3 '14 at 10:47

1 Answer 1

This can be achieved using the original MP4/h264 files and the media9 package.

By default, the video player component VPlayer.swf of the media9 package doesn't loop MP4 video, but rather keeps the last frame after reaching the end.

In the example below, three videos are started right after opening the document/page (thanks to the Flash variable setting autoPlay=true). The example uses the files cube.mp4 and cubeposter.png from the media9 CTAN package.

\documentclass{beamer}
\usepackage{media9}

\begin{document}
\begin{frame}{Three Video Example}

\includemedia[
  label=vid1,
  width=0.33\linewidth,
  addresource=cube.mp4,
  activate=pageopen,
  flashvars={
     source=cube.mp4
    &autoPlay=true
  }
]{\includegraphics{cubeposter}}{VPlayer.swf}\hfill%
\includemedia[
  label=vid2,
  width=0.33\linewidth,
  addresource=cube.mp4,
  activate=pageopen,
  flashvars={
     source=cube.mp4
    &autoPlay=true
  }
]{\includegraphics{cubeposter}}{VPlayer.swf}\hfill%
\includemedia[
  label=vid3,
  width=0.33\linewidth,
  addresource=cube.mp4,
  activate=pageopen,
  flashvars={
     source=cube.mp4
    &autoPlay=true
  }
]{\includegraphics{cubeposter}}{VPlayer.swf}

\centerline{\mediabutton[
  mediacommand=vid1:play,
  mediacommand=vid2:play,
  mediacommand=vid3:play
]{\fbox{Play all at once}}}
\end{frame}
\end{document}
share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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