Sound "Dilema"

Ok the reason I use Dilema is because it is a dilema and not a problem…

Ok, I am hoping to allow the user to choose 1 of 4 tracks to listen to and for it to loop indefinately, I also want Volume and Pan controls.

In Cool Edit I make a seamless loop ie - you can’t tell where it goes back to start because it all sounds the same.

When I save it as a mp3 format it adds about 1second of “nothing” a quiet part - this screws up the loop. Its not just Cooledit that does this, but goldwave, and yes soundforge. They all BLOODY do it… god knows why.

The way I usually get round this is to save it as a .wav then import into flash, then convert it to .mp3 within flash its self.

The only way I know of that you can control sound in such ways as volume and pan is to :

a) have it in the library to start with
b) import it dynamically

for my site I can’t do a) because the file will become too large
and I can’t do b) because it ruins my loop (Flash doesn’t allow you to import in .wav format)

What Do I Do!?

Is there anyway I can use loadmovie to load in a separate .swf into my main movie with sound attached to it then control that sound ? Thats the only possible way I can think of solving this but as said earlier I wouldn’t know how to do this.

If you can think of any way around this problem please post.

Hi,
With the first part of your Q, yes, just drop your sound into an fla, publish as an swf and in your main movie, use loadMovie to load it in when called.
With controlling the sound, I assume you mean control from the mainMovie, there is a book by Sham Bhangal called Foundation ActionScript and there is a tute in there that shows how to build a pan control and volume slider - its quite cool and is in chapter 8. I think the friendsofEd site is still up, if so you can download chapter 8 from there.
The book was written for F5, but it should be convertible to MX with ease. The only thing you will have to look out for is addressing the _level that the sound swf is on. I would load the sound swf into a blank clip, then you only have to address the clip and not worry about _levels.

Hope that halps

SteveD

http://www.friendsofed.com/

Hi,

I knew how to make the sound and pan controls (it even tells you in F1) so I had no probs there - just wasn’t sure how to control sound on loaded in .swf or if you even could.

One of the files wouldn’t download, however I managed to get the one I really needed and I am pretty sure I know how to do it now.

Cheers!