This week's book giveaway is in the OCMJEA forum.
We're giving away four copies of OCM Java EE 6 Enterprise Architect Exam Guide and have Paul Allen & Joseph Bambara on-line!
See this thread for details.
The moose likes Game Development and the fly likes browsers, sounds and media players Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of OCM Java EE 6 Enterprise Architect Exam Guide this week in the OCMJEA forum!
JavaRanch » Java Forums » Java » Game Development
Bookmark "browsers, sounds and media players" Watch "browsers, sounds and media players" New topic
Author

browsers, sounds and media players

Tom Clement
Greenhorn

Joined: Mar 21, 2004
Posts: 26
I tried this question in other forums with no responses, maybe
I've been in the wrong ones.

One of my applets, one that uses a few sound clips, takes control
of my sound device and won't return control until the browser's closed.
Even if you go to another website! I'd like to know if I'm missing some code, besides "stop" which would force the applet to relinquish control.

here's the basic code:

public void playsound(String soundeffect)
{
soundfile = getAudioClip(getCodeBase(),soundeffect);

if(soundfile != null)
soundfile.play();


}//end playsound

Can anyone help? Thanks, Tom
 
With a little knowledge, a cast iron skillet is non-stick and lasts a lifetime.
 
subject: browsers, sounds and media players