Open chentengming opened 6 years ago
The not continuous could be caused by echo. Could you provide some advise?
消除回声可以用 AcousticEchoCanceler @ChillingVan 在 mAudioRecord.startRecording() 之前执行
// 消除回声导致的滋啦滋啦声音
if (AcousticEchoCanceler.isAvailable()) {
aec = AcousticEchoCanceler.create(mAudioRecord.getAudioSessionId());
if (aec != null) {
aec.setEnabled(true); //android 11 issue low volume
}
}
if (AutomaticGainControl.isAvailable()) {
agc = AutomaticGainControl.create(mAudioRecord.getAudioSessionId());
if (agc != null) {
agc.setEnabled(true);
}
}
mAudioRecord.startRecording();
mMediaCodec.start();
Black screen appears on the push stream and the sound is not continuous, Thanks.