如何将Android AudioRecord缓冲区作为数字数组?

时间:2014-06-02 07:52:23

标签: android casting audiorecord

有没有办法将AudioRecord缓冲区作为数字数组,例如float数组?数组的简单类型转换似乎不起作用,但我没有找到文档缓冲区数据的样子。

我按如下方式获取缓冲区:

recorder = new AudioRecord(...);
...
byte buffer[] = new byte[bufferSize];
....
while(isRecording){
      read = recorder.read(buffer, 0, bufferSize);
      //-->How do I get buffer as number array?
...

0 个答案:

没有答案