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

Side by Side Diff: webrtc/call/call.cc

Issue 1757683002: Make the audio channel communicate network state changes to the call. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 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 | « no previous file | webrtc/media/engine/webrtcvoiceengine.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) 2013 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2013 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 532 matching lines...) Expand 10 before | Expand all | Expand 10 after
543 return; 543 return;
544 } 544 }
545 config_.bitrate_config = bitrate_config; 545 config_.bitrate_config = bitrate_config;
546 congestion_controller_->SetBweBitrates(bitrate_config.min_bitrate_bps, 546 congestion_controller_->SetBweBitrates(bitrate_config.min_bitrate_bps,
547 bitrate_config.start_bitrate_bps, 547 bitrate_config.start_bitrate_bps,
548 bitrate_config.max_bitrate_bps); 548 bitrate_config.max_bitrate_bps);
549 } 549 }
550 550
551 void Call::SignalNetworkState(NetworkState state) { 551 void Call::SignalNetworkState(NetworkState state) {
552 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread()); 552 RTC_DCHECK(configuration_thread_checker_.CalledOnValidThread());
553 // TODO(skvlad): In the unbundled case the network state might be different
554 // for the audio and video channels. Currently the last change wins.
555 // Correctly handling this scenario would require tracking the network state
556 // for each media type separately.
stefan-webrtc 2016/03/02 08:25:59 Do we think this is a common scenario? In that cas
pbos-webrtc 2016/03/02 12:54:34 Does this risk audio/video network states being ou
skvlad 2016/03/02 18:44:05 This sounds like a good idea - let's keep the spec
skvlad 2016/03/02 18:44:05 Currently the audio/video MediaChannels each deter
553 network_enabled_ = state == kNetworkUp; 557 network_enabled_ = state == kNetworkUp;
554 congestion_controller_->SignalNetworkState(state); 558 congestion_controller_->SignalNetworkState(state);
555 { 559 {
556 ReadLockScoped write_lock(*send_crit_); 560 ReadLockScoped write_lock(*send_crit_);
557 for (auto& kv : audio_send_ssrcs_) { 561 for (auto& kv : audio_send_ssrcs_) {
558 kv.second->SignalNetworkState(state); 562 kv.second->SignalNetworkState(state);
559 } 563 }
560 for (auto& kv : video_send_ssrcs_) { 564 for (auto& kv : video_send_ssrcs_) {
561 kv.second->SignalNetworkState(state); 565 kv.second->SignalNetworkState(state);
562 } 566 }
(...skipping 181 matching lines...) Expand 10 before | Expand all | Expand 10 after
744 // thread. Then this check can be enabled. 748 // thread. Then this check can be enabled.
745 // RTC_DCHECK(!configuration_thread_checker_.CalledOnValidThread()); 749 // RTC_DCHECK(!configuration_thread_checker_.CalledOnValidThread());
746 if (RtpHeaderParser::IsRtcp(packet, length)) 750 if (RtpHeaderParser::IsRtcp(packet, length))
747 return DeliverRtcp(media_type, packet, length); 751 return DeliverRtcp(media_type, packet, length);
748 752
749 return DeliverRtp(media_type, packet, length, packet_time); 753 return DeliverRtp(media_type, packet, length, packet_time);
750 } 754 }
751 755
752 } // namespace internal 756 } // namespace internal
753 } // namespace webrtc 757 } // namespace webrtc
OLDNEW
« no previous file with comments | « no previous file | webrtc/media/engine/webrtcvoiceengine.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698