| 1 |
\RequirePackage{flashmovie} |
| 2 |
% it is neccessay to use "\RequirePackage{flashmovie}" because beamer |
| 3 |
% also uses "\pdfminorversion". see flashmovie.sty for an explanation. |
| 4 |
|
| 5 |
%--------------------------------------------- |
| 6 |
% jw-player-example |
| 7 |
%--------------------------------------------- |
| 8 |
|
| 9 |
\documentclass[10pt]{beamer} |
| 10 |
|
| 11 |
\usepackage[english]{babel} |
| 12 |
\usepackage{hyperref} |
| 13 |
|
| 14 |
\usetheme{Warsaw} % Warsaw,Hannover,boxes |
| 15 |
\usecolortheme{rose} % orchid,lily,dolphin,beetle,crane |
| 16 |
\usefonttheme{professionalfonts} % professionalfonts,serif |
| 17 |
\useinnertheme{rounded} % rounded |
| 18 |
\useoutertheme{shadow} % shadow,sidebar,split |
| 19 |
|
| 20 |
%--------------------------------------------- |
| 21 |
|
| 22 |
\setbeamersize{text margin left=0.3cm} % small margins |
| 23 |
\setbeamersize{text margin right=0.3cm} |
| 24 |
|
| 25 |
%--------------------------------------------- |
| 26 |
% for writing a document is is convenient to switch movies off. to do this, |
| 27 |
% use "blank=1" as an option. in order to use the videos, use "blank=0". |
| 28 |
% |
| 29 |
% to make thinks easy, use "blank=\myblank" as an option and define |
| 30 |
% \myblank as suitable. |
| 31 |
|
| 32 |
\def\myblank{0} |
| 33 |
%\def\myblank{1} |
| 34 |
|
| 35 |
%\def\mymovie{saturn5} |
| 36 |
\def\mymovie{flagmoon} % if the noise of saturn5 annoyes to much |
| 37 |
|
| 38 |
%--------------------------------------------- |
| 39 |
|
| 40 |
\title[flashmovie.sty]{flashmovie.sty} |
| 41 |
\author[\href{mailto:[email protected]}{Timo Hartmann}]{\href{mailto:[email protected]}{Timo Hartmann}} |
| 42 |
|
| 43 |
\date[2010]{} |
| 44 |
|
| 45 |
%--------------------------------------------- |
| 46 |
|
| 47 |
\begin{document} |
| 48 |
|
| 49 |
\frame{ |
| 50 |
|
| 51 |
\titlepage |
| 52 |
|
| 53 |
\begin{block}{\alert{Warning}} |
| 54 |
It is recommended to use the latest available version of the Adobe Reader |
| 55 |
to view PDF files generated with flashmovie.sty. |
| 56 |
% Otherwise your Adobe Reader may die a sudden painfull death... |
| 57 |
\end{block} |
| 58 |
|
| 59 |
} % end frame |
| 60 |
|
| 61 |
%--------------------------------------------- |
| 62 |
|
| 63 |
\begin{frame} |
| 64 |
|
| 65 |
\frametitle{Basics} |
| 66 |
|
| 67 |
\begin{minipage}[t]{6.1cm} |
| 68 |
\vspace{0cm} |
| 69 |
\flashmovie[width=6cm,height=5cm,engine=jw-player,auto=1,blank=\myblank]{\mymovie.mp4} |
| 70 |
\end{minipage} |
| 71 |
\begin{minipage}[t]{5.7cm} |
| 72 |
\vspace{0cm} |
| 73 |
This package allows direct embedding of flash movies into PDF files. It is |
| 74 |
designed for use with pdflatex. |
| 75 |
\vspace{0.5cm} |
| 76 |
|
| 77 |
Basically it uses the fact that the Adobe Reader 9 contains an embedded Adobe Flash |
| 78 |
player which can be invoked with the ``rich media annotation'' feature which is described |
| 79 |
in ``Adobe Supplement to the ISO 32000 BaseVersion: 1.7 ExtensionLevel: 3''. |
| 80 |
\vspace{0.5cm} |
| 81 |
|
| 82 |
This means that you can only use flashmovie.sty in combination |
| 83 |
with Adobe Reader 9 and upwards. |
| 84 |
|
| 85 |
\end{minipage} |
| 86 |
|
| 87 |
\vspace{0.5cm} |
| 88 |
|
| 89 |
P.S.: This sample video is courtesy of the NASA ( \href{http://heasarc.gsfc.nasa.gov/Videos/historical/\mymovie.avi}{\mymovie.avi} ). |
| 90 |
|
| 91 |
\end{frame} |
| 92 |
|
| 93 |
%--------------------------------------------- |
| 94 |
|
| 95 |
\begin{frame}[fragile] |
| 96 |
|
| 97 |
\frametitle{\href{http://www.longtailvideo.com/players/jw-flv-player}{JW Player}} |
| 98 |
|
| 99 |
The source code used for the video on the previous page is: |
| 100 |
|
| 101 |
\begin{verbatim} |
| 102 |
\flashmovie[width=6cm,height=5cm, |
| 103 |
engine=jw-player,auto=1]{movie.mp4} |
| 104 |
\end{verbatim} |
| 105 |
|
| 106 |
This means that the movie is rendered with the |
| 107 |
\href{http://www.longtailvideo.com/players/jw-flv-player}{``JW Player''} |
| 108 |
from longtail video (\href{http://www.longtailvideo.com}{www.longtailvideo.com}). |
| 109 |
|
| 110 |
\vspace{0.5cm} |
| 111 |
|
| 112 |
This is an open source flash player released under a |
| 113 |
\href{http://creativecommons.org/licenses/by-nc-sa/3.0/}{non-commercial license}, |
| 114 |
which means its free for non-commercial use. |
| 115 |
|
| 116 |
\end{frame} |
| 117 |
|
| 118 |
%--------------------------------------------- |
| 119 |
|
| 120 |
\begin{frame}[fragile] |
| 121 |
|
| 122 |
\frametitle{Issues with the flv-player} |
| 123 |
|
| 124 |
\begin{itemize} |
| 125 |
|
| 126 |
\item Sadly the \href{http://flv-player.net}{flv-player} does not work |
| 127 |
reliably with the latex package beamer. If you try it, the acrobat reader |
| 128 |
often crashes while trying to change the page. I have no idea |
| 129 |
what is the cause of this problem. |
| 130 |
|
| 131 |
\item The only reliable way to use beamer seems to be directly embedding the videos as |
| 132 |
flash animations or to use the JW player. |
| 133 |
|
| 134 |
\end{itemize} |
| 135 |
|
| 136 |
\end{frame} |
| 137 |
|
| 138 |
%--------------------------------------------- |
| 139 |
|
| 140 |
\begin{frame}[fragile] |
| 141 |
|
| 142 |
\frametitle{Options for the \href{http://www.longtailvideo.com/players/jw-flv-player}{JW Player}} |
| 143 |
|
| 144 |
\begin{minipage}[t]{4.1cm} |
| 145 |
\vspace{0cm} |
| 146 |
\flashmovie[width=4cm,height=3cm,engine=jw-player,auto=0,controlbar=0,blank=\myblank]{\mymovie.mp4} |
| 147 |
\end{minipage} |
| 148 |
\begin{minipage}[t]{7cm} |
| 149 |
\vspace{0cm} |
| 150 |
In this example the video is not started before the user clicks on it. The controlbar is disabled, too. |
| 151 |
\begin{verbatim} |
| 152 |
\flashmovie[width=4cm,height=3cm, |
| 153 |
engine=jw-player,auto=0, |
| 154 |
controlbar=0]{movie.mp4} |
| 155 |
\end{verbatim} |
| 156 |
\end{minipage} |
| 157 |
|
| 158 |
\begin{minipage}[t]{4.1cm} |
| 159 |
\vspace{0cm} |
| 160 |
\flashmovie[width=4cm,height=3cm,engine=jw-player,auto=0,image=saturn.jpg,blank=\myblank,loop=1]{\mymovie.mp4} |
| 161 |
\end{minipage} |
| 162 |
\begin{minipage}[t]{7cm} |
| 163 |
\vspace{0cm} |
| 164 |
Here additionally an image is displayed before the movie starts. The movie also loops. |
| 165 |
\begin{verbatim} |
| 166 |
\flashmovie[width=4cm,height=3cm, |
| 167 |
engine=jw-player,auto=0, |
| 168 |
image=saturn.jpg,loop=1] |
| 169 |
{movie.mp4} |
| 170 |
\end{verbatim} |
| 171 |
\end{minipage} |
| 172 |
|
| 173 |
\end{frame} |
| 174 |
|
| 175 |
%--------------------------------------------- |
| 176 |
|
| 177 |
\end{document} |