OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. |
3 * | 3 * |
4 * Use of this source code is governed by a BSD-style license | 4 * Use of this source code is governed by a BSD-style license |
5 * that can be found in the LICENSE file in the root of the source | 5 * that can be found in the LICENSE file in the root of the source |
6 * tree. An additional intellectual property rights grant can be found | 6 * tree. An additional intellectual property rights grant can be found |
7 * in the file PATENTS. All contributing project authors may | 7 * in the file PATENTS. All contributing project authors may |
8 * be found in the AUTHORS file in the root of the source tree. | 8 * be found in the AUTHORS file in the root of the source tree. |
9 */ | 9 */ |
10 | 10 |
(...skipping 704 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
715 // Ensure that the stream delay was set before the call to the | 715 // Ensure that the stream delay was set before the call to the |
716 // AECM ProcessCaptureAudio function. | 716 // AECM ProcessCaptureAudio function. |
717 if (public_submodules_->echo_control_mobile->is_enabled() && | 717 if (public_submodules_->echo_control_mobile->is_enabled() && |
718 !was_stream_delay_set()) { | 718 !was_stream_delay_set()) { |
719 return AudioProcessing::kStreamParameterNotSetError; | 719 return AudioProcessing::kStreamParameterNotSetError; |
720 } | 720 } |
721 | 721 |
722 RETURN_ON_ERR(public_submodules_->echo_control_mobile->ProcessCaptureAudio( | 722 RETURN_ON_ERR(public_submodules_->echo_control_mobile->ProcessCaptureAudio( |
723 ca, stream_delay_ms())); | 723 ca, stream_delay_ms())); |
724 | 724 |
| 725 if (capture_nonlocked_.beamformer_enabled) { |
| 726 private_submodules_->beamformer->PostFilter(*ca->split_data_f(), |
| 727 ca->split_data_f()); |
| 728 } |
| 729 |
725 public_submodules_->voice_detection->ProcessCaptureAudio(ca); | 730 public_submodules_->voice_detection->ProcessCaptureAudio(ca); |
726 | 731 |
727 if (constants_.use_experimental_agc && | 732 if (constants_.use_experimental_agc && |
728 public_submodules_->gain_control->is_enabled() && | 733 public_submodules_->gain_control->is_enabled() && |
729 (!capture_nonlocked_.beamformer_enabled || | 734 (!capture_nonlocked_.beamformer_enabled || |
730 private_submodules_->beamformer->is_target_present())) { | 735 private_submodules_->beamformer->is_target_present())) { |
731 private_submodules_->agc_manager->Process( | 736 private_submodules_->agc_manager->Process( |
732 ca->split_bands_const(0)[kBand0To8kHz], ca->num_frames_per_band(), | 737 ca->split_bands_const(0)[kBand0To8kHz], ca->num_frames_per_band(), |
733 capture_nonlocked_.split_rate); | 738 capture_nonlocked_.split_rate); |
734 } | 739 } |
(...skipping 726 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
1461 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config); | 1466 debug_dump_.capture.event_msg->mutable_config()->CopyFrom(config); |
1462 | 1467 |
1463 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), | 1468 RETURN_ON_ERR(WriteMessageToDebugFile(debug_dump_.debug_file.get(), |
1464 &debug_dump_.num_bytes_left_for_log_, | 1469 &debug_dump_.num_bytes_left_for_log_, |
1465 &crit_debug_, &debug_dump_.capture)); | 1470 &crit_debug_, &debug_dump_.capture)); |
1466 return kNoError; | 1471 return kNoError; |
1467 } | 1472 } |
1468 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP | 1473 #endif // WEBRTC_AUDIOPROC_DEBUG_DUMP |
1469 | 1474 |
1470 } // namespace webrtc | 1475 } // namespace webrtc |
OLD | NEW |