/**
*
* @param fileName
* @param fileType
* @param fileFormat
*/
JSStreamingSampleRecorder(JSMinim sys,
String fileName,
AudioFileFormat.Type fileType,
AudioFormat fileFormat,
int bufferSize)
{
name = fileName;
type = fileType;
format = fileFormat;
system = sys;
try
{
aos = AudioSystemShadow.getAudioOutputStream( type, format,
AudioSystem.NOT_SPECIFIED,
new File(name) );
}
catch (IOException e)
{
system.error("Error obtaining new output stream: " + e.getMessage());
}
catch (IllegalArgumentException badarg)
{
system.error("Error obtaining new output stream for " + fileName + " with type "
+ type.toString() + " format " + format.toString()
+ " and bufferSize " + bufferSize + ".\n"
+ "The reason is " + badarg.getMessage());
}
fsb = new FloatSampleBuffer(format.getChannels(),
bufferSize,
format.getSampleRate());
recording = false;
}
JSStreamingSampleRecorder.java 文件源码
java
阅读 17
收藏 0
点赞 0
评论 0
项目:romanov
作者:
评论列表
文章目录