PDA

View Full Version : Audio integration problem


Godomac37
08-18-2008, 02:17 PM
Hi everyone,

I have a problem with audio integration into my current project. I would like to have a changeable graphic in the user interface. The sound should start, once the user clicks onto the graphic. A second click should stop the sound.

So far I was able to edit the sound volume. But I need to stop the sound. Here is what I got so far:

<!--// SOUND INTEGRATION //-->
<spot id="audio" url="sounds/audio.swf" repeat="0" pan="0" tilt="0" enableSoundPannig="0" soundRadius="360" />

<box id="speaker_off" linked="pano-test" depth="0" orientation="sphere" rotationX="0" rotationY="0" visible="0" scale="1" url="images/speaker_off.png" pan="50" tilt="20" onClick="audio.soundVolume=1; visible=0; speaker_on.visible=1" />

<box id="speaker_on" linked="pano-test" depth="0" orientation="sphere" rotationX="0" rotationY="0" scale="1" url="images/black_speaker_on.png" pan="50" tilt="20" onClick="audio.soundVolume=0; visible=0; speaker_off.visible=1" />


If someone could provide some code snippets or a link to an existing tutorial - I would apprechiate that a lot.

Thanks for any kind of help.

Regards,
Guido

Scott Witte
08-19-2008, 09:25 PM
Guido,

Why not use the supplied MP3 player? You can click the sound on and off with that as well as adjust volume. If you want a custom graphic you can change it by editing the fla file. Of course, that supposes you have a copy of Flash and understand how to use it....