10.04.2013 Views

The rmannot Package: Demo of MP3 Player

The rmannot Package: Demo of MP3 Player

The rmannot Package: Demo of MP3 Player

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

AcroTEX.Net<br />

<strong>The</strong> <strong>rmannot</strong> <strong>Package</strong><br />

<strong>Demo</strong> <strong>of</strong> <strong>MP3</strong> <strong>Player</strong><br />

D. P. Story<br />

Copyright c○ 2010 dpstory@acrotex.net http://www.acrotex.net<br />

Prepared: June 21, 2010 Published: July 2008


<strong>The</strong> Tardis <strong>of</strong> Dr. Who<br />

Above is the basic appearance <strong>of</strong> the <strong>MP3</strong> file, basically, just the control bar.<br />

On the next page is a fancy version, obtained by using a graphic background.


Currently, a rich media annotation has not hidden property, you can, however, move it<br />

<strong>of</strong>f the page and control the play using a form button or link action.<br />

Here are examples: A form field or a link play the tardis!<br />

<strong>The</strong> verbatim listing is given below.<br />

Here are examples:\makebox[0pt][r]{\resizebox{!}{5bp}<br />

{\rmAnnot[name=TardisOfDrWho]{268bp}{28bp}{tardis}}\hspace{24in}}<br />

A form field {\small\pushButton[\textSize{7}\CA{Play!}\S{S}\A{\JS{%<br />

var rm=this.getAnnotRichMedia({nPage: this.pageNum, cName: "TardisOfDrWho"});\r<br />

if (rm.activated) rm.callAS("multimedia_play");\r<br />

else rm.activated=true;<br />

}}]{tardisBtn}{}{9bp}} or a link<br />

\setLinkText[\A{\JS{%<br />

var rm=this.getAnnotRichMedia({nPage: this.pageNum, cName: "TardisOfDrWho"});\r<br />

if (rm.activated) rm.callAS("multimedia_play");\r<br />

else rm.activated=true;<br />

}}]{play the tardis}!<br />

Using the above techniques, you can also place a link around, for example, a graphic<br />

that plays the <strong>MP3</strong> when clicked. See the demo file tst flv asjs.tex for a discussion<br />

<strong>of</strong> using Acrobat JavaScript to play a rich media clip.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!