I have a beamer
presentation that I am creating and I'm trying to embed a video clip. I'm using the media9
package and having a ton of issues with it. I've gone through the documentation with a fine-toothed comb but I'm still striking out. Here's what I have done so far:
First, I modified the video file into MP4/H.264
using ffmpeg
as the media9
documentation instructs. The code I used is directly from the documentation:
ffmpeg -i /filepath/file.mp4 -vf scale="trunc(iw/2)*2:trunc(ih/2)*2" -c:v
libx264 -profile:v high -pix_fmt yuv420p -g 30 -r 30 /filepath/file2.mp4
Then, I added this code to my beamer
presentation:
\includemedia[
width=0.7\linewidth,
height=0.5\linewidth,
activate=onclick,
addresource=/filepath/file2.MP4,
flashvars={source=/filepath/file2.MP4}
]{}{StrobeMediaPlayback.swf}
After doing this, the presentation compiles fully with no errors or notes in the console about media9
, the file, or anything related to the video.
However, when I open it in Adobe Acrobat Pro x (Mac OS X 10.10.3), I get the error We are unable to connect to the content you've requested. We apologize for the inconvenience.
After clicking around the video, the message will change and display TypeError - Error #1009
I've tried using VPlayer.swf
instead and that didn't work. I've tried using different settings on ffmpeg
to convert the video differently, and I'm just not sure if I'm missing something.
Best Answer
The correct FlashVar for setting the video source in
StrobeMediaPlayback.swf
isotherwise, the reported error occurs.
The following MWE should work: