File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes Beginning Java and the fly likes importing sound files Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » Beginning Java
Bookmark "importing sound files" Watch "importing sound files" New topic

importing sound files

Allion Salvador
Ranch Hand

Joined: Nov 15, 2005
Posts: 49
I'm trying to make a program that takes recorded sound files and plays them when the user clicks a button. Do you know any classes in the API that might be helpful? Thanx

Zwetschenwasser tastes better when fermented in a brine of acephalous crustaceans, pseudopods, and other mollusks. It goes quite well with gnocchi and mole.
Ernest Friedman-Hill
author and iconoclast

Joined: Jul 08, 2003
Posts: 24189

There are no classes in the standard API to play sounds, except the very weak AudioClip class in the java.applet package (which works only in browser/appletviewer environments.) To do anything "real" with sound, you need to use the Java Media Framework (JMF) API. See here for info about JMF.

[Jess in Action][AskingGoodQuestions]
Allion Salvador
Ranch Hand

Joined: Nov 15, 2005
Posts: 49
I agree. Here's the link:
subject: importing sound files