Latex Beamer - Media9:为媒体按钮和播放按钮着色

Latex Beamer - Media9:为媒体按钮和播放按钮着色

我当前的代码如下

\begin{frame}
\frametitle{Introduction To AWS}
\hspace{-0.8cm}    
\includemedia[
 label=myVidPlayer,
 width=10cm,height=6cm,
 activate=pageopen,
 addresource=1.flv,
 addresource=2.flv,
 addresource=3.flv,
 addresource=4.flv,
 flashvars={
     source=1.flv %video to be shown at first
    &autoPlay=true
    &scaleMode=letterbox %useful, if videos are of different aspect ratio
 }
]{}{VPlayer.swf}


\mediabutton[mediacommand=myVidPlayer:setSource [(1.flv)]]{Alexa}
\mediabutton[mediacommand=myVidPlayer:setSource [(2.flv)]]{Philip Robot}
\mediabutton[mediacommand=myVidPlayer:setSource [(3.flv)]]{Sophia} 
\mediabutton[mediacommand=myVidPlayer:setSource [(4.flv)]]{Bot Simulation}


\end{frame}

1) 如何为媒体按钮添加颜色?

它们现在的样子有点令人不安,因为它们全是白色的,所以看起来都是连在一起的。我可以把它们做得更漂亮或给它们上色吗?

2)我可以添加播放和暂停按钮吗?

3)我可以将视频置于中央吗?

目前来看: 在此处输入图片描述

谢谢!

答案1

  1. 我怎样才能为媒体按钮添加颜色?

您可以将“Alexa”替换为您喜欢的任何命令来创建彩色按钮,例如\colorbox{<color>}{<text>}

\documentclass{beamer}

\usepackage{media9}

\begin{document}

\begin{frame}
\frametitle{Introduction To AWS}
\hspace{-0.8cm}    
\includemedia[
 label=myVidPlayer,
 width=10cm,height=6cm,
 activate=pageopen,
 addresource=video01.flv,
 flashvars={
     source=video01.flv %video to be shown at first
    &autoPlay=true
    &scaleMode=letterbox %useful, if videos are of different aspect ratio
 }
]{}{VPlayer.swf}

\mediabutton[mediacommand=myVidPlayer:setSource [(video01.flv)]]{\colorbox{red}{\strut Alexa}}


\end{frame}


\end{document}
  1. 我可以将视频置于中心吗?

您可以使用\hfill视频之前和之后

\documentclass{beamer}

\usepackage{media9}

\begin{document}

\begin{frame}
\frametitle{Introduction To AWS}
{
\hfill
\includemedia[
 label=myVidPlayer,
 width=10cm,height=6cm,
 activate=pageopen,
 addresource=video01.flv,
 flashvars={
     source=video01.flv %video to be shown at first
    &autoPlay=true
    &scaleMode=letterbox %useful, if videos are of different aspect ratio
 }
]{}{VPlayer.swf}
\hfill
}

\mediabutton[mediacommand=myVidPlayer:setSource [(video01.flv)]]{Alexa}


\end{frame}


\end{document}

相关内容