简体   繁体   English

Android:AudioRecord 和 DynamicsProcessing

[英]Android: AudioRecord and DynamicsProcessing

Currently I am recording audio using AudioRecord , and I want to implement EQ, compressor and limiter audio filters.目前我正在使用AudioRecord录制音频,我想实现均衡器、压缩器和限制器音频过滤器。 that DynamicsProcessing is just what I need, but the key thing is that it typically supposed to work with MediaPlayer or AudioTrack , which means that the effects are applied during playing the already prerecorded audio sample. DynamicsProcessing正是我所需要的,但关键是它通常应该与MediaPlayerAudioTrack ,这意味着在播放已经预先录制的音频样本期间应用效果。

But what I need is to apply these filters during recording, so that the resulting file will contain already filtered audio.但我需要的是在录制期间应用这些过滤器,以便生成的文件将包含已过滤的音频。

Is it possible to achieve this using DynamicsProcessing and somehow binding it to the AudioRecord instance?是否可以使用DynamicsProcessing并以某种方式将其绑定到AudioRecord实例来实现这一点? Or are there some other ways to apply such a filters during audio recording native to SDK or using some existing library?或者是否有其他方法可以在 SDK 本地录音或使用某些现有库期间应用此类过滤器?

PS: I couldn't find anything relevant and the only idea that came up is implementing the filtering of the data gained via AudioRecord#read by hands, which, I believe, will take quite a while for a person that isn't familiar with audio engineering. PS:我找不到任何相关的东西,唯一的想法是实现对通过AudioRecord#read by AudioRecord#read获得的数据进行过滤,我相信这对于不熟悉的人来说需要很AudioRecord#read音频工程。

The answer is No .答案是否定的

You can't attach the DP effect to the AudioRecord through SDK API .您无法通过SDK API将 DP 效果附加到AudioRecord

Look at the Sound Amplifier app, it deployed DynamicsProcessing features but re-implementing it with a standalone shared native library.看看Sound Amplifier应用程序,它部署了DynamicsProcessing功能,但使用独立的共享本机库重新实现它。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM