一,实例化和配置
AudioProcessing* apm = AudioProcessing::Create(0); //这里的0指的是channelID,只是一个标注那个通道的表示
apm->level_estimator()->Enable(true);//启用 重试次数估计 组件
apm->echo_cancellation()->Enable(true);//启用回声消除组件
apm->echo_cancellation()->enable_metrics(true);//
apm->echo_cancellation()->enable_drift_compensation(true);//启用时钟补偿模块(声音捕捉设备的时钟频率和
播放设备的时钟频率可能不一样)
apm->gain_control()->Enable(true);//启用增益控制组件,client必须启用哦!
apm->high_pass_filter()->Enable(true);//高通过滤器组件,过滤DC偏移和低频噪音,client必须启用
apm->noise_suppression()->Enable(true);//噪声抑制组件,client必须启用
apm->voice_detection()->Enable(true);//启用语音检测组件,检测是否有说话声
apm->voice_detection()->set_likelihood( VoiceDetection::kModerateLikelihood);//设置语音检测的