Sign in to follow this  
encom

[java] AudioClip pb

Recommended Posts

Hi, I'm using AudioClip to play a sound. I have a pb : i dont know how to make play() blockant. clip = Applet.newAudioClip(new URL("file", "localhost", fileName_1)); clip.play(); clip = Applet.newAudioClip(new URL("file", "localhost", fileName_2)); clip.play(); it only plays de second one. I want it to play the first THEN the second. How could i do ?

Share this post


Link to post
Share on other sites
Not that it helps you out, but this seems to be contradicting its specification:

Multiple AudioClip items can be playing at the same time, and the resulting sound is mixed together
to produce a composite.


Note that AudioClip is basically the most simple as it gets. Perhaps have a look at javax.sound.sampled.Clip, which allows you to check whether a sound is currently playing.

Greetz,

Illco

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

Sign in to follow this