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

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

Issue 1337003003: Add a name to the ProcessThread constructor. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Comments addressed. Created 5 years, 3 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
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/shared_data.h" 11 #include "webrtc/voice_engine/shared_data.h"
12 12
13 #include "webrtc/modules/audio_processing/include/audio_processing.h" 13 #include "webrtc/modules/audio_processing/include/audio_processing.h"
14 #include "webrtc/system_wrappers/interface/critical_section_wrapper.h" 14 #include "webrtc/system_wrappers/interface/critical_section_wrapper.h"
15 #include "webrtc/system_wrappers/interface/trace.h" 15 #include "webrtc/system_wrappers/interface/trace.h"
16 #include "webrtc/voice_engine/channel.h" 16 #include "webrtc/voice_engine/channel.h"
17 #include "webrtc/voice_engine/output_mixer.h" 17 #include "webrtc/voice_engine/output_mixer.h"
18 #include "webrtc/voice_engine/transmit_mixer.h" 18 #include "webrtc/voice_engine/transmit_mixer.h"
19 19
20 namespace webrtc { 20 namespace webrtc {
21 21
22 namespace voe { 22 namespace voe {
23 23
24 static int32_t _gInstanceCounter = 0; 24 static int32_t _gInstanceCounter = 0;
25 25
26 SharedData::SharedData(const Config& config) : 26 SharedData::SharedData(const Config& config)
27 _instanceId(++_gInstanceCounter), 27 : _instanceId(++_gInstanceCounter),
28 _apiCritPtr(CriticalSectionWrapper::CreateCriticalSection()), 28 _apiCritPtr(CriticalSectionWrapper::CreateCriticalSection()),
29 _channelManager(_gInstanceCounter, config), 29 _channelManager(_gInstanceCounter, config),
30 _engineStatistics(_gInstanceCounter), 30 _engineStatistics(_gInstanceCounter),
31 _audioDevicePtr(NULL), 31 _audioDevicePtr(NULL),
32 _moduleProcessThreadPtr(ProcessThread::Create()) 32 _moduleProcessThreadPtr(ProcessThread::Create("VoiceProcessThread")) {
33 {
34 Trace::CreateTrace(); 33 Trace::CreateTrace();
35 if (OutputMixer::Create(_outputMixerPtr, _gInstanceCounter) == 0) 34 if (OutputMixer::Create(_outputMixerPtr, _gInstanceCounter) == 0)
36 { 35 {
37 _outputMixerPtr->SetEngineInformation(_engineStatistics); 36 _outputMixerPtr->SetEngineInformation(_engineStatistics);
38 } 37 }
39 if (TransmitMixer::Create(_transmitMixerPtr, _gInstanceCounter) == 0) 38 if (TransmitMixer::Create(_transmitMixerPtr, _gInstanceCounter) == 0)
40 { 39 {
41 _transmitMixerPtr->SetEngineInformation(*_moduleProcessThreadPtr, 40 _transmitMixerPtr->SetEngineInformation(*_moduleProcessThreadPtr,
42 _engineStatistics, 41 _engineStatistics,
43 _channelManager); 42 _channelManager);
(...skipping 65 matching lines...) Expand 10 before | Expand all | Expand 10 after
109 } 108 }
110 109
111 void SharedData::SetLastError(int32_t error, TraceLevel level, 110 void SharedData::SetLastError(int32_t error, TraceLevel level,
112 const char* msg) const { 111 const char* msg) const {
113 _engineStatistics.SetLastError(error, level, msg); 112 _engineStatistics.SetLastError(error, level, msg);
114 } 113 }
115 114
116 } // namespace voe 115 } // namespace voe
117 116
118 } // namespace webrtc 117 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698