<Sound Dev>  Review Request: 8146239 Support of PCM_FLOAT for the AU file format
Sergey.Bylokhov at oracle.com
Fri Feb 26 13:17:05 UTC 2016
Hello, Audio Guru.
Please review the small fix for jdk9.
According to specification  AU file format can contains the data in
the float encoding. When support of AU was added to the jdk the float
encoding was not supported. But in jdk 7 PCM_FLOAT was added(for WAV)
and it can be reused for AU as well.
1) AuFileFormat.java/AuFileReader.java: the pcm_float was added to the
- The "if" statement in getAudioFileFormat() was reworked. Its
purpose was to change the type PCM_UNSIGNED to PCM_SIGNED(because au
support only signed pcm). But it was written in some strange manner.
Note that this method returns the type which should be used in the saved
- In the getFileStream() I removed the checks and always converts
the input stream to the AudioFileFormat which was returned from the
getAudioFileFormat() and the AudioSystem.getAudioInputStream() will
recognize conversion is needed or not
Webrev can be found at: http://cr.openjdk.java.net/~serb/8146239/webrev.00
Best regards, Sergey.
More information about the sound-dev