Using Mixed Sound Tutorial
This page demonstrates using SoundExtender to play multiple sounds or music simultaneously. Try clicking the buttons below to get an idea.
Browsers do not natively support playing more than one sound simultaneously. So, to accomplish this, a Flash player object is used. Credit goes to
Scott Schiller
for his work on a wrapper for Flash sound playback, which is the core of SoundBehavior.
Steps to Using SoundExtender
1. First, note that the following files will need to be placed in your web application directory:
soundcontroller.swf - the flash file that performs mixed sound playback
sound-config.xml - an xml file containing a list of sound files that you wish to play.
2. Add any sound files you wish to play to sound-config.xml. If the sound files are in a subdirectory, be sure to set the baseHref property to the subdirectory.
3. Add a ScriptManager, GameWindowExtender, and SoundExtender to your page. Set the TargetControlId of the SoundExtender to the GameWindowExtender.
4. You can use the play method of the SoundExtender, passing the Id of the sound file as defined in sound-config.xml.
$find('SoundExtender1').play('fishhit1');