## LaTeX forum ⇒ Graphics, Figures & Tables ⇒ media9 package questions

Information and discussion about graphics, figures & tables in LaTeX documents.
VanillaThunder
Posts: 1
Joined: Sat Mar 09, 2013 4:29 pm

### media9 package questions

Hello,

I am using the media9 package to include several animations into my document. For this purpose I am using the following code:

\begin{figure}[H]    \includemedia[      activate=pageopen,      width=\VideoWidth,height=\VideoHeight,      addresource=###file###.flv,      flashvars={src=###file###.flv&scaleMode=letterbox&controlBarAutoHideTimeout=1}    ]{}{StrobeMediaPlayback.swf}    \caption{###Caption###} \end{figure}

1. Is it possible to only set the width or height and the other value will be set automatically?

2. Is it possible to set an alternative image or select a frame of the animation that will be displayed when the document gets printed?

Thank you for your help!

Tags:

localghost
Site Moderator
Posts: 9204
Joined: Fri Feb 02, 2007 12:06 pm
Just for information to other users for awareness of possibly already existing solutions. The question has also been posted to goLaTeX and MrUnix (two German LaTeX forums). Please read what our administrator thinks about that.

Did you read the media9 manual? I think it will at least answer your first question. If that doesn't help, prepare self-contained and minimal example to give an adequate problem description.

Thorsten
LaTeX Community Moderator

¹ System: openSUSE 42.2 (Linux 4.4.52), TeX Live 2016 (vanilla), TeXworks 0.6.1

alex
Posts: 32
Joined: Mon May 19, 2008 10:53 am
VanillaThunder wrote:Hello,

I am using the media9 package to include several animations into my document. For this purpose I am using the following code:

\begin{figure}[H]    \includemedia[      activate=pageopen,      width=\VideoWidth,height=\VideoHeight,      addresource=###file###.flv,      flashvars={src=###file###.flv&scaleMode=letterbox&controlBarAutoHideTimeout=1}    ]{}{StrobeMediaPlayback.swf}    \caption{###Caption###} \end{figure}

1. Is it possible to only set the width or height and the other value will be set automatically?

TeX cannot parse media files. You will have to provide the information about the video size by either using both options or by supplying a poster text or image (read on!).

VanillaThunder wrote:2. Is it possible to set an alternative image or select a frame of the animation that will be displayed when the document gets printed?

This is the purpose of the (currently empty, in your example) poster argument. You can \includegraphics an image file there. It will be shown in case the video is not activated, and it gets printed. Moreover, the poster dimensions are used to determine the size of the video box, making resizing options (width, height, depth, scale) optional.

All this is written on the first pages of the media9 docs.

Return to “Graphics, Figures & Tables”

### Who is online

Users browsing this forum: No registered users and 2 guests