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

Side by Side Diff: webrtc/voice_engine/voe_base_impl.cc

Issue 2729053002: Add location to RegisterModule (Closed)
Patch Set: Format BUILD.gn Created 3 years, 9 months 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 unified diff | Download patch
« no previous file with comments | « webrtc/voice_engine/transmit_mixer.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
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
11 #include "webrtc/voice_engine/voe_base_impl.h" 11 #include "webrtc/voice_engine/voe_base_impl.h"
12 12
13 #include "webrtc/api/audio_codecs/builtin_audio_decoder_factory.h" 13 #include "webrtc/api/audio_codecs/builtin_audio_decoder_factory.h"
14 #include "webrtc/base/format_macros.h" 14 #include "webrtc/base/format_macros.h"
15 #include "webrtc/base/location.h"
15 #include "webrtc/base/logging.h" 16 #include "webrtc/base/logging.h"
16 #include "webrtc/common_audio/signal_processing/include/signal_processing_librar y.h" 17 #include "webrtc/common_audio/signal_processing/include/signal_processing_librar y.h"
17 #include "webrtc/modules/audio_coding/include/audio_coding_module.h" 18 #include "webrtc/modules/audio_coding/include/audio_coding_module.h"
18 #include "webrtc/modules/audio_device/audio_device_impl.h" 19 #include "webrtc/modules/audio_device/audio_device_impl.h"
19 #include "webrtc/modules/audio_processing/include/audio_processing.h" 20 #include "webrtc/modules/audio_processing/include/audio_processing.h"
20 #include "webrtc/system_wrappers/include/file_wrapper.h" 21 #include "webrtc/system_wrappers/include/file_wrapper.h"
21 #include "webrtc/voice_engine/channel.h" 22 #include "webrtc/voice_engine/channel.h"
22 #include "webrtc/voice_engine/include/voe_errors.h" 23 #include "webrtc/voice_engine/include/voe_errors.h"
23 #include "webrtc/voice_engine/output_mixer.h" 24 #include "webrtc/voice_engine/output_mixer.h"
24 #include "webrtc/voice_engine/transmit_mixer.h" 25 #include "webrtc/voice_engine/transmit_mixer.h"
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
206 } else { 207 } else {
207 // Use the already existing external ADM implementation. 208 // Use the already existing external ADM implementation.
208 shared_->set_audio_device(external_adm); 209 shared_->set_audio_device(external_adm);
209 LOG_F(LS_INFO) 210 LOG_F(LS_INFO)
210 << "An external ADM implementation will be used in VoiceEngine"; 211 << "An external ADM implementation will be used in VoiceEngine";
211 } 212 }
212 213
213 // Register the ADM to the process thread, which will drive the error 214 // Register the ADM to the process thread, which will drive the error
214 // callback mechanism 215 // callback mechanism
215 if (shared_->process_thread()) { 216 if (shared_->process_thread()) {
216 shared_->process_thread()->RegisterModule(shared_->audio_device()); 217 shared_->process_thread()->RegisterModule(shared_->audio_device(),
218 RTC_FROM_HERE);
217 } 219 }
218 220
219 bool available = false; 221 bool available = false;
220 222
221 // -------------------- 223 // --------------------
222 // Reinitialize the ADM 224 // Reinitialize the ADM
223 225
224 // Register the AudioObserver implementation 226 // Register the AudioObserver implementation
225 if (shared_->audio_device()->RegisterEventObserver(this) != 0) { 227 if (shared_->audio_device()->RegisterEventObserver(this) != 0) {
226 shared_->SetLastError( 228 shared_->SetLastError(
(...skipping 538 matching lines...) Expand 10 before | Expand all | Expand 10 after
765 shared_->SetLastError(VE_CHANNEL_NOT_VALID, kTraceError, 767 shared_->SetLastError(VE_CHANNEL_NOT_VALID, kTraceError,
766 "AssociateSendChannel() failed to locate accociate_send_channel"); 768 "AssociateSendChannel() failed to locate accociate_send_channel");
767 return -1; 769 return -1;
768 } 770 }
769 771
770 channel_ptr->set_associate_send_channel(ch); 772 channel_ptr->set_associate_send_channel(ch);
771 return 0; 773 return 0;
772 } 774 }
773 775
774 } // namespace webrtc 776 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/voice_engine/transmit_mixer.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698