Skip to content

Commit

Permalink
fix: Fix can't open mic alone when built-in AEC is enabled. (#29)
Browse files Browse the repository at this point in the history
  • Loading branch information
cloudwebrtc authored Jun 7, 2022
1 parent 9843970 commit 57b3569
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions audio/audio_state.cc
Original file line number Diff line number Diff line change
Expand Up @@ -104,6 +104,14 @@ void AudioState::AddSendingStream(webrtc::AudioSendStream* stream,
if (!adm->Recording()) {
if (adm->InitRecording() == 0) {
if (recording_enabled_) {
#if defined(WEBRTC_WIN)
if (adm->BuiltInAECIsAvailable() && !adm->Playing()) {
if (!adm->PlayoutIsInitialized()) {
adm->InitPlayout();
}
adm->StartPlayout();
}
#endif
adm->StartRecording();
}
} else {
Expand Down

0 comments on commit 57b3569

Please sign in to comment.