Tag: okio

用Okio创建WAV文件

我的系统需要使用WAV文件数组的字节创建一个WAV文件。 目前它使用Okio在缓冲区中读写数据,然后将数据写入最终文件。 我正在关注这个文件和这个堆栈溢出问题: http://tiny.systems/software/soundProgrammer/WavFormatDocs.pdf https://stackoverflow.com/a/12370312/2430555 和… Okio:1.10.0 Kotlin:1.0.2-1 Java:1.7 我创建了这个代码: fun mixAudios() { try { //Create the file used to storage the mixed audio file. val file = File(directory, finalFileName) //Open the buffer for this file. val bufferedSink = Okio.buffer(Okio.appendingSink(file)) //Data header of the file. val header = Buffer() //Data of the file. val data […]