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

Side by Side Diff: remoting/protocol/webrtc_audio_module.h

Issue 2437453004: Removing the dependency on //third_party/webrtc:webrtc and replacing with rtc_base. (Closed)
Patch Set: Fixing :: typo. Created 4 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 unified diff | Download patch
« no previous file with comments | « remoting/protocol/ice_connection_to_client.cc ('k') | remoting/protocol/webrtc_audio_module.cc » ('j') | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 // Copyright 2016 The Chromium Authors. All rights reserved. 1 // Copyright 2016 The Chromium Authors. All rights reserved.
2 // Use of this source code is governed by a BSD-style license that can be 2 // Use of this source code is governed by a BSD-style license that can be
3 // found in the LICENSE file. 3 // found in the LICENSE file.
4 4
5 #ifndef REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_ 5 #ifndef REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_
6 #define REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_ 6 #define REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_
7 7
8 #include "base/memory/ref_counted.h" 8 #include "base/memory/ref_counted.h"
9 #include "base/synchronization/lock.h" 9 #include "base/synchronization/lock.h"
10 #include "base/timer/timer.h" 10 #include "base/timer/timer.h"
(...skipping 117 matching lines...) Expand 10 before | Expand all | Expand 10 after
128 int32_t GetLoudspeakerStatus(bool* enabled) const override; 128 int32_t GetLoudspeakerStatus(bool* enabled) const override;
129 bool BuiltInAECIsAvailable() const override; 129 bool BuiltInAECIsAvailable() const override;
130 bool BuiltInAGCIsAvailable() const override; 130 bool BuiltInAGCIsAvailable() const override;
131 bool BuiltInNSIsAvailable() const override; 131 bool BuiltInNSIsAvailable() const override;
132 int32_t EnableBuiltInAEC(bool enable) override; 132 int32_t EnableBuiltInAEC(bool enable) override;
133 int32_t EnableBuiltInAGC(bool enable) override; 133 int32_t EnableBuiltInAGC(bool enable) override;
134 int32_t EnableBuiltInNS(bool enable) override; 134 int32_t EnableBuiltInNS(bool enable) override;
135 135
136 // Only supported on iOS. 136 // Only supported on iOS.
137 #if defined(WEBRTC_IOS) 137 #if defined(WEBRTC_IOS)
138 int GetPlayoutAudioParameters(AudioParameters* params) const override; 138 int GetPlayoutAudioParameters(webrtc::AudioParameters* params) const override;
139 int GetRecordAudioParameters(AudioParameters* params) const override; 139 int GetRecordAudioParameters(webrtc::AudioParameters* params) const override;
140 #endif // WEBRTC_IOS 140 #endif // WEBRTC_IOS
141 141
142 private: 142 private:
143 void StartPlayoutOnAudioThread(); 143 void StartPlayoutOnAudioThread();
144 void StopPlayoutOnAudioThread(); 144 void StopPlayoutOnAudioThread();
145 145
146 void PollFromSource(); 146 void PollFromSource();
147 147
148 scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner_; 148 scoped_refptr<base::SingleThreadTaskRunner> audio_task_runner_;
149 149
150 // |lock_| must be locked when accessing |initialized_|, |playing_| and 150 // |lock_| must be locked when accessing |initialized_|, |playing_| and
151 // |audio_transport_|. 151 // |audio_transport_|.
152 mutable base::Lock lock_; 152 mutable base::Lock lock_;
153 153
154 bool initialized_ = false; 154 bool initialized_ = false;
155 bool playing_ = false; 155 bool playing_ = false;
156 webrtc::AudioTransport* audio_transport_ = nullptr; 156 webrtc::AudioTransport* audio_transport_ = nullptr;
157 157
158 // Timer running on the |audio_task_runner_| that polls audio from 158 // Timer running on the |audio_task_runner_| that polls audio from
159 // |audio_transport_|. 159 // |audio_transport_|.
160 base::RepeatingTimer poll_timer_; 160 base::RepeatingTimer poll_timer_;
161 }; 161 };
162 162
163 } // namespace protocol 163 } // namespace protocol
164 } // namespace remoting 164 } // namespace remoting
165 165
166 #endif // REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_ 166 #endif // REMOTING_PROTOCOL_WEBRTC_AUDIO_MODULE_H_
OLDNEW
« no previous file with comments | « remoting/protocol/ice_connection_to_client.cc ('k') | remoting/protocol/webrtc_audio_module.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698