从 AVAudioPlayer 获取原始音频样本
我正在使用 AVAudioPlayer 加载 .caf 文件,并且我想获取指向音频样本的指针。有什么办法可以做到这一点吗?我知道 AVAudioPlayer 有一个 NSData 属性,我假设它是从 .caf 文件读取的字节。我可以去掉 .caf 标头吗?我不认为样本以 LPCM 形式存储在 .caf 文件中,所以我觉得我必须进行转换。
有没有比使用 AVAudioPlayer 加载 .caf 文件并访问示例更简单的方法?
I'm loading in a .caf file with AVAudioPlayer, and I'd like to get at a pointer to the audio samples. Is there any way to go about doing this? I know AVAudioPlayer has an NSData property which I assume is the bytes read in from the .caf file. Could I just strip the .caf header? I don't think the samples are stored as LPCM in .caf files, so I feel like I'd have to convert.
Is there an easier method than using AVAudioPlayer to load up a .caf file and have access to the samples?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论