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

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

Issue 1267683002: Hooked up RtcEventLog. It lives in Voice Engine and pointers are propagated to ACM and Call. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Initial version Created 5 years, 4 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 #ifndef WEBRTC_VOICE_ENGINE_SHARED_DATA_H 11 #ifndef WEBRTC_VOICE_ENGINE_SHARED_DATA_H
12 #define WEBRTC_VOICE_ENGINE_SHARED_DATA_H 12 #define WEBRTC_VOICE_ENGINE_SHARED_DATA_H
13 13
14 #include "webrtc/base/scoped_ptr.h" 14 #include "webrtc/base/scoped_ptr.h"
15 #include "webrtc/modules/audio_device/include/audio_device.h" 15 #include "webrtc/modules/audio_device/include/audio_device.h"
16 #include "webrtc/modules/audio_processing/include/audio_processing.h" 16 #include "webrtc/modules/audio_processing/include/audio_processing.h"
17 #include "webrtc/modules/utility/interface/process_thread.h" 17 #include "webrtc/modules/utility/interface/process_thread.h"
18 #include "webrtc/voice_engine/channel_manager.h" 18 #include "webrtc/voice_engine/channel_manager.h"
19 #include "webrtc/voice_engine/statistics.h" 19 #include "webrtc/voice_engine/statistics.h"
20 #include "webrtc/voice_engine/voice_engine_defines.h" 20 #include "webrtc/voice_engine/voice_engine_defines.h"
21 21
22 class ProcessThread; 22 class ProcessThread;
23 23
24 namespace webrtc { 24 namespace webrtc {
25 class Config; 25 class Config;
26 class CriticalSectionWrapper; 26 class CriticalSectionWrapper;
27 class RtcEventLog;
27 28
28 namespace voe { 29 namespace voe {
29 30
30 class TransmitMixer; 31 class TransmitMixer;
31 class OutputMixer; 32 class OutputMixer;
32 33
33 class SharedData 34 class SharedData
34 { 35 {
35 public: 36 public:
36 // Public accessors. 37 // Public accessors.
(...skipping 11 matching lines...) Expand all
48 void set_ext_recording(bool value) { _externalRecording = value; } 49 void set_ext_recording(bool value) { _externalRecording = value; }
49 bool ext_playout() const { return _externalPlayout; } 50 bool ext_playout() const { return _externalPlayout; }
50 void set_ext_playout(bool value) { _externalPlayout = value; } 51 void set_ext_playout(bool value) { _externalPlayout = value; }
51 ProcessThread* process_thread() { return _moduleProcessThreadPtr.get(); } 52 ProcessThread* process_thread() { return _moduleProcessThreadPtr.get(); }
52 AudioDeviceModule::AudioLayer audio_device_layer() const { 53 AudioDeviceModule::AudioLayer audio_device_layer() const {
53 return _audioDeviceLayer; 54 return _audioDeviceLayer;
54 } 55 }
55 void set_audio_device_layer(AudioDeviceModule::AudioLayer layer) { 56 void set_audio_device_layer(AudioDeviceModule::AudioLayer layer) {
56 _audioDeviceLayer = layer; 57 _audioDeviceLayer = layer;
57 } 58 }
59 RtcEventLog* event_log() { return _eventLog.get(); }
58 60
59 int NumOfSendingChannels(); 61 int NumOfSendingChannels();
60 int NumOfPlayingChannels(); 62 int NumOfPlayingChannels();
61 63
62 // Convenience methods for calling statistics().SetLastError(). 64 // Convenience methods for calling statistics().SetLastError().
63 void SetLastError(int32_t error) const; 65 void SetLastError(int32_t error) const;
64 void SetLastError(int32_t error, TraceLevel level) const; 66 void SetLastError(int32_t error, TraceLevel level) const;
65 void SetLastError(int32_t error, TraceLevel level, 67 void SetLastError(int32_t error, TraceLevel level,
66 const char* msg) const; 68 const char* msg) const;
67 69
68 protected: 70 protected:
69 const uint32_t _instanceId; 71 const uint32_t _instanceId;
70 CriticalSectionWrapper* _apiCritPtr; 72 CriticalSectionWrapper* _apiCritPtr;
71 ChannelManager _channelManager; 73 ChannelManager _channelManager;
72 Statistics _engineStatistics; 74 Statistics _engineStatistics;
73 AudioDeviceModule* _audioDevicePtr; 75 AudioDeviceModule* _audioDevicePtr;
74 OutputMixer* _outputMixerPtr; 76 OutputMixer* _outputMixerPtr;
75 TransmitMixer* _transmitMixerPtr; 77 TransmitMixer* _transmitMixerPtr;
76 rtc::scoped_ptr<AudioProcessing> audioproc_; 78 rtc::scoped_ptr<AudioProcessing> audioproc_;
77 rtc::scoped_ptr<ProcessThread> _moduleProcessThreadPtr; 79 rtc::scoped_ptr<ProcessThread> _moduleProcessThreadPtr;
80 rtc::scoped_ptr<RtcEventLog> _eventLog;
78 81
79 bool _externalRecording; 82 bool _externalRecording;
80 bool _externalPlayout; 83 bool _externalPlayout;
81 84
82 AudioDeviceModule::AudioLayer _audioDeviceLayer; 85 AudioDeviceModule::AudioLayer _audioDeviceLayer;
83 86
84 SharedData(const Config& config); 87 SharedData(const Config& config);
85 virtual ~SharedData(); 88 virtual ~SharedData();
86 }; 89 };
87 90
88 } // namespace voe 91 } // namespace voe
89 92
90 } // namespace webrtc 93 } // namespace webrtc
91 #endif // WEBRTC_VOICE_ENGINE_SHARED_DATA_H 94 #endif // WEBRTC_VOICE_ENGINE_SHARED_DATA_H
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698