How can I play a .wav file in a JDK 1.1.x applet?
First of all, JDK 1.1 generally only provides μ-law, 8000Hz mono playback. It does not provide .wav file playback directly. And for playback of audio data of the application, there are only the “unofficial” sun.audio.* classes. So you’d need to write your own classes that read in the .wav files, convert the sound data to μ-law and then use the sun.audio.* classes to play them. For code that parses .wav files and does μ-law conversion look at Tritonus’ source code: WaveAudioFileReader and TConversionTool. Tritonus classes are under the LGPL licence. Regarding sun.audio.* classes: it is discouraged to use them. I heard that they don’t work anymore as expected in JDK 1.3. My applets using them work well from JDK 1.0 to JDK 1.1 and in all browsers that I could put my hand on.