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

Side by Side Diff: voice_engine/channel_proxy.cc

Issue 3019433002: Remove VoECodec (Closed)
Patch Set: rebase Created 3 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
« no previous file with comments | « voice_engine/channel_proxy.h ('k') | voice_engine/include/voe_codec.h » ('j') | 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) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 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
(...skipping 179 matching lines...) Expand 10 before | Expand all | Expand 10 after
190 void ChannelProxy::SetBitrate(int bitrate_bps, int64_t probing_interval_ms) { 190 void ChannelProxy::SetBitrate(int bitrate_bps, int64_t probing_interval_ms) {
191 // This method can be called on the worker thread, module process thread 191 // This method can be called on the worker thread, module process thread
192 // or on a TaskQueue via VideoSendStreamImpl::OnEncoderConfigurationChanged. 192 // or on a TaskQueue via VideoSendStreamImpl::OnEncoderConfigurationChanged.
193 // TODO(solenberg): Figure out a good way to check this or enforce calling 193 // TODO(solenberg): Figure out a good way to check this or enforce calling
194 // rules. 194 // rules.
195 // RTC_DCHECK(worker_thread_checker_.CalledOnValidThread() || 195 // RTC_DCHECK(worker_thread_checker_.CalledOnValidThread() ||
196 // module_process_thread_checker_.CalledOnValidThread()); 196 // module_process_thread_checker_.CalledOnValidThread());
197 channel()->SetBitRate(bitrate_bps, probing_interval_ms); 197 channel()->SetBitRate(bitrate_bps, probing_interval_ms);
198 } 198 }
199 199
200 void ChannelProxy::SetRecPayloadType(int payload_type,
201 const SdpAudioFormat& format) {
202 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
203 const int result = channel()->SetRecPayloadType(payload_type, format);
204 RTC_DCHECK_EQ(0, result);
205 }
206
207 void ChannelProxy::SetReceiveCodecs( 200 void ChannelProxy::SetReceiveCodecs(
208 const std::map<int, SdpAudioFormat>& codecs) { 201 const std::map<int, SdpAudioFormat>& codecs) {
209 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread()); 202 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
210 channel()->SetReceiveCodecs(codecs); 203 channel()->SetReceiveCodecs(codecs);
211 } 204 }
212 205
213 void ChannelProxy::SetSink(std::unique_ptr<AudioSinkInterface> sink) { 206 void ChannelProxy::SetSink(std::unique_ptr<AudioSinkInterface> sink) {
214 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread()); 207 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
215 channel()->SetSink(std::move(sink)); 208 channel()->SetSink(std::move(sink));
216 } 209 }
(...skipping 110 matching lines...) Expand 10 before | Expand all | Expand 10 after
327 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread()); 320 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
328 channel()->OnTwccBasedUplinkPacketLossRate(packet_loss_rate); 321 channel()->OnTwccBasedUplinkPacketLossRate(packet_loss_rate);
329 } 322 }
330 323
331 void ChannelProxy::OnRecoverableUplinkPacketLossRate( 324 void ChannelProxy::OnRecoverableUplinkPacketLossRate(
332 float recoverable_packet_loss_rate) { 325 float recoverable_packet_loss_rate) {
333 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread()); 326 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
334 channel()->OnRecoverableUplinkPacketLossRate(recoverable_packet_loss_rate); 327 channel()->OnRecoverableUplinkPacketLossRate(recoverable_packet_loss_rate);
335 } 328 }
336 329
337 void ChannelProxy::RegisterLegacyReceiveCodecs() {
338 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
339 channel()->RegisterLegacyReceiveCodecs();
340 }
341
342 std::vector<RtpSource> ChannelProxy::GetSources() const { 330 std::vector<RtpSource> ChannelProxy::GetSources() const {
343 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread()); 331 RTC_DCHECK(worker_thread_checker_.CalledOnValidThread());
344 return channel()->GetSources(); 332 return channel()->GetSources();
345 } 333 }
346 334
347 Channel* ChannelProxy::channel() const { 335 Channel* ChannelProxy::channel() const {
348 RTC_DCHECK(channel_owner_.channel()); 336 RTC_DCHECK(channel_owner_.channel());
349 return channel_owner_.channel(); 337 return channel_owner_.channel();
350 } 338 }
351 339
352 } // namespace voe 340 } // namespace voe
353 } // namespace webrtc 341 } // namespace webrtc
OLDNEW
« no previous file with comments | « voice_engine/channel_proxy.h ('k') | voice_engine/include/voe_codec.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698