?
Solved

small audio sampler/player

Posted on 2003-12-03
2
Medium Priority
?
360 Views
Last Modified: 2010-04-03
I'm building a site for a client that wants a small audio sampler in their site, it will play 10 sounds in mp3 format and the user will have the capacity to download the individual sounds in .wav format, these will be stored in zip files and called using the geturl function.

The sounds need to play independently of each other, so if a user clicks on sound4 for example, any other sound will cease to play. I'm thinking of using the stopallsounds function as the first piece of script on each button that launches the streaming sound, will this create any problems?

What i'm unsure of before i beign building the player is how i should put it together for optimum usability. Would it be best to load all the textual info from an xml file and manually code the buttons or would it be possible to make it in such a way that the xml file, (or a php file?) dynamically creates the necessary play and download button for each sound in the xml. I've looked at using id3 but since the data cannot be loaded until the sound has downloaded i dont think this will work with streaming sounds.

if someone could point me in the right direction and potentially lay out the bare bones of the application it would be hugely appreciated.

Thanks.
0
Comment
Question by:robjmills
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
2 Comments
 
LVL 1

Author Comment

by:robjmills
ID: 9873953
anyone??
0
 
LVL 1

Accepted Solution

by:
seengee earned 700 total points
ID: 9882062
i'd just do it exactly as you said, use this script on each button to launch the sound and stop all others,

on(press)
{
      stopAllSounds();
      mp3Player = new Sound(this);
      mp3Player.loadSound("samples/yourSound.mp3", true);
      mp3Player.start();
}

and this for the zips:

on (release) {
      getURL("samples/zips/yourSound.zip");
}

and just hand code the rest, as the sounds are streaming the file will never be that big, if you want you could load this whole file into another file to keep the loading off the main timeline. you would do this by using a blank mc on the main timeline and using this;

myMc.loadMovie("audio.swf");

enjoy!.
0

Featured Post

Industry Leaders: We Want Your Opinion!

We value your feedback.

Take our survey and automatically be enter to win anyone of the following:
Yeti Cooler, Amazon eGift Card, and Movie eGift Card!

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

Introduction This article is primarily concerned with ActionScript 3 and generally specific to AVM2.  Most suggestions would apply to ActionScript 2 as well, and I've noted those tips that differ between AS2 and AS3. With the advent of ActionS…
Recently, I was asked to recommend a tracking system to be implemented on a clients website. As the entire site was built on flash, my first thought was to suggest custom built tracking system. However, our company at that point of time didn't h…
The goal of the tutorial is to teach the user how to how to load their YouTube profile onto Flash Media Live Encoder.
The goal of the tutorial is to teach the user how to select the video input device. Make sure you have an input device that in connected and work and recognized by Adobe Flash Media Live Encoder and select it in the “video input” menu.
Suggested Courses

801 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question