|
Playing Audio in an Applet |
|
|
Playing an audio clip in a Java applet can be done as shown in the following example.
public void init() {
// Load audio clip
AudioClip ac = getAudioClip(getDocumentBase(),
"http://hostname.com/my-audio.au");
// Play audio clip
ac.play();
// Stop playing audio clip
ac.stop();
// Play audio clip continuously
ac.loop();
}
|
Related Tips
|
Page 1 of 0 ( 0 comments )
You can share your information about this topic using the form below!
Please do not post your questions with this form! Thanks.