Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(27)

Unified Diff: webrtc/modules/audio_processing/echo_control_mobile_impl.cc

Issue 1422013002: Preparational work for an upcoming addition of a threadchecking scheme for APM (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@bundling_of_state_CL
Patch Set: Fixed the final threadchecker refactoring issues (and merged from latest master) Created 5 years, 1 month ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: webrtc/modules/audio_processing/echo_control_mobile_impl.cc
diff --git a/webrtc/modules/audio_processing/echo_control_mobile_impl.cc b/webrtc/modules/audio_processing/echo_control_mobile_impl.cc
index a32c77c1420cdbbc62032bc38bc1cb3119d89b6f..a653519fe22a70829c562ed53538857f9b1269cb 100644
--- a/webrtc/modules/audio_processing/echo_control_mobile_impl.cc
+++ b/webrtc/modules/audio_processing/echo_control_mobile_impl.cc
@@ -68,11 +68,14 @@ size_t EchoControlMobile::echo_path_size_bytes() {
return WebRtcAecm_echo_path_size_bytes();
}
-EchoControlMobileImpl::EchoControlMobileImpl(const AudioProcessing* apm,
- CriticalSectionWrapper* crit)
+EchoControlMobileImpl::EchoControlMobileImpl(
+ const AudioProcessing* apm,
+ CriticalSectionWrapper* crit,
+ const rtc::ThreadChecker* render_thread_checker)
: ProcessingComponent(),
apm_(apm),
crit_(crit),
+ render_thread_checker_(render_thread_checker),
routing_mode_(kSpeakerphone),
comfort_noise_enabled_(true),
external_echo_path_(NULL),
@@ -86,6 +89,7 @@ EchoControlMobileImpl::~EchoControlMobileImpl() {
}
int EchoControlMobileImpl::ProcessRenderAudio(const AudioBuffer* audio) {
+ RTC_DCHECK(render_thread_checker_->CalledOnValidThread());
if (!is_component_enabled()) {
return apm_->kNoError;
}

Powered by Google App Engine
This is Rietveld 408576698