Home -> FPP plugins page -> soundspot.swf
This plugin is completely free for use in any context or connection.
soundspot.swf
This is a modification of the FPP hotspot plugin mp3hotspot.swf. Code has been added to check the file="..." attribute for play, pause and stop commands. And by specifying the onComplete="..." attribute in your hotspot, you can execute any FPP commands at the end of your sound file. The original mp3hotspot.swf is written by Denis V. Chumakov for http://flashpanoramas.com/
Hotspot attributes:

filefile="pause"use to load mp3 file and control file playback
repeatrepeat="5"the number of times the mp3 file will be played
onCompleteonComplete="global.play2()"FPP command(s) to be executed at end of sound file


Plugin control:

The plugin is checking the hotspot file="..." attribute for file info and for commands that will control the playback of the mp3 file. The following commands are supported:

playfile="play"start playing the mp3 file
pausefile="pause"pause the mp3 player
stopfile="stop"stop mp3 player
or
file=""
Everything else passed in the file="..." attribute will be interpreted as an URL to your mp3 file.



NOTES:

One difference from the original mp3hotspot.swf is that you cannot pass any parameters in the hotspot url="..." attribute - you have to use the file="..." and the repeat="..." attributes.

When a sound file has finished playing, the file="..." attribute will be cleared by the plugin before executing any onComplete="..." commands.

The onComplete="..." attribute can of course be used to load a new sound file when the first one has finished, and by making a chain of loads, you can play as many files as you like. Don't forget to add the "global." prefix if you want to execute a global function.




Example FPP XML file:

...
<!-- mp3 player -->
<spot id="player" url="soundspot.swf" file="" repeat="0" pan="18" tilt="0" enableSoundPanning="0" soundRadius="180" soundVolume="0.2"
   onComplete="global.soundStop()"
/>

<!-- play/pause buttons -->
<spot id="btn_play" url="/panos/images/com/play1.png" static="1" align="BC" salign="BC" staticX="80" staticY="-22"
   visible="1" alpha="0"
   onClick="player.file=play;soundStart()"
/>
<spot id="btn_pause" url="/panos/images/com/pause1.png" static="1" align="BC" salign="BC" staticX="120" staticY="-22"
   visible="1" alpha="0"
   onClick="player.file=pause"
/>
<spot id="btn_stop" url="/panos/images/com/stop1.png" static="1" align="BC" salign="BC" staticX="160" staticY="-22"
   visible="1" alpha="0"
   onClick="player.file=stop;soundStop()"
/>

...

Version history:
1.2:
Sound can now be replayed after having been stopped, by simply giving a "play" command.

1.1:
When the sound file has finished playing, the file="..." attribute is cleared by the plugin.