e727. determining the encoding of a sampled audio file.txt
来自「这里面包含了一百多个JAVA源文件」· 文本 代码 · 共 17 行
TXT
17 行
try {
// From file
AudioInputStream stream = AudioSystem.getAudioInputStream(new File("audiofile"));
// From URL
stream = AudioSystem.getAudioInputStream(new URL("http://hostname/audiofile"));
AudioFormat format = stream.getFormat();
if (format.getEncoding() == AudioFormat.Encoding.ULAW) {
} else if (format.getEncoding() == AudioFormat.Encoding.ULAW) {
}
} catch (MalformedURLException e) {
} catch (IOException e) {
} catch (UnsupportedAudioFileException e) {
// Audio format is not supported.
}
⌨️ 快捷键说明
复制代码Ctrl + C
搜索代码Ctrl + F
全屏模式F11
增大字号Ctrl + =
减小字号Ctrl + -
显示快捷键?