Name: jl125535 Date: 11/18/2002
FULL PRODUCT VERSION :
java version "1.4.1"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.1-b21)
Java HotSpot(TM) Client VM (build 1.4.1-b21, mixed mode)
java version "1.4.0_01"
Java(TM) 2 Runtime Environment, Standard Edition (build 1.4.0_01-b03)
Java HotSpot(TM) Client VM (build 1.4.0_01-b03, mixed mode)
The behaviour is virtually identical in 1.4.1_01. The 16bit sounds sound slightly different ?!? But the click still occurs on 8bit.
FULL OPERATING SYSTEM VERSION :
Microsoft Windows 2000 [Version 5.00.2195]
A DESCRIPTION OF THE PROBLEM :
We are getting louds clicks when playing 8-bit mono WAV
files through the javax.media.sound.sampled API. When
these files are converted to 16-bit mono WAV files, the
clicking problems disappear.
A scan through the bug database reveals bug 4266439 which
was previously fixed 1999-11-10. What we are seeing
appears to exactly match the symptoms of this bug - is it
possible that it has re-appeared?
We are often looping very short WAV files, and this bug can
therefore be quite apparent.
STEPS TO FOLLOW TO REPRODUCE THE PROBLEM :
1. Play very short 8-bit WAV file (can provide if
necessary). Loop Repeatedly. Listen to result.
EXPECTED VERSUS ACTUAL BEHAVIOR :
Sound should play acceptably. Instead, loud clicks / pops
are heard as the sound loops.
REPRODUCIBILITY :
This bug can be reproduced always.
---------- BEGIN SOURCE ----------
import java.net.URL;
import java.io.*;
public class AudioTest
{
public static void main(String[] args)
{
new AudioTest();
System.exit(0);
}
public AudioTest()
{
try
{
Clip theClip = (Clip) AudioSystem.getLine(
new Line.Info(Clip.class));
AudioInputStream ais1 =
AudioSystem.getAudioInputStream(
new File("test8bitmono.wav"));
AudioInputStream ais2 =
AudioSystem.getAudioInputStream(
new File("test8bitstereo.wav"));
AudioInputStream ais3 =
AudioSystem.getAudioInputStream(
new File("test16bitmono.wav"));
AudioInputStream ais4 =
AudioSystem.getAudioInputStream(
new File("test16bitstereo.wav"));
AudioInputStream[] aiss = new AudioInputStream[4];
aiss[0] = ais1;
aiss[1] = ais2;
aiss[2] = ais3;
aiss[3] = ais4;
for (int i=0; i < aiss.length; i++)
{
AudioInputStream ais = aiss[i];
System.out.println("ais = " + ais.getFormat());
theClip.open(ais);
theClip.loop(Clip.LOOP_CONTINUOUSLY);
try
{
Object o = new Object();
synchronized(o)
{
o.wait(2000);
}
}
catch (InterruptedException iex)
{
}
theClip.close();
}
}
catch (Exception e)
{
e.printStackTrace();
}
}
}
---------- END SOURCE ----------
Release Regression From : 1.3.1
The above release value was the last known release where this
bug was known to work. Since then there has been a regression.
(Review ID: 159396)
======================================================================
Verified in Sol 9, RH8.0, win 2000 Professional SP3.
###@###.### 2003-03-03