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

Side by Side Diff: webrtc/pc/channel.cc

Issue 2041593002: Revert "Revert of Update the BWE when the network route changes. (patchset #5 id:180001 of https://… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@master
Patch Set: Mark a route as disconnect if it is not ready to send media Created 4 years, 6 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 2004 The WebRTC project authors. All Rights Reserved. 2 * Copyright 2004 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 586 matching lines...) Expand 10 before | Expand all | Expand 10 after
597 void BaseChannel::OnSelectedCandidatePairChanged( 597 void BaseChannel::OnSelectedCandidatePairChanged(
598 TransportChannel* channel, 598 TransportChannel* channel,
599 CandidatePairInterface* selected_candidate_pair, 599 CandidatePairInterface* selected_candidate_pair,
600 int last_sent_packet_id) { 600 int last_sent_packet_id) {
601 ASSERT(channel == transport_channel_ || channel == rtcp_transport_channel_); 601 ASSERT(channel == transport_channel_ || channel == rtcp_transport_channel_);
602 RTC_DCHECK(network_thread_->IsCurrent()); 602 RTC_DCHECK(network_thread_->IsCurrent());
603 std::string transport_name = channel->transport_name(); 603 std::string transport_name = channel->transport_name();
604 rtc::NetworkRoute network_route; 604 rtc::NetworkRoute network_route;
605 if (selected_candidate_pair) { 605 if (selected_candidate_pair) {
606 network_route = rtc::NetworkRoute( 606 network_route = rtc::NetworkRoute(
607 selected_candidate_pair->ReadyToSendMedia(),
607 selected_candidate_pair->local_candidate().network_id(), 608 selected_candidate_pair->local_candidate().network_id(),
608 selected_candidate_pair->remote_candidate().network_id(), 609 selected_candidate_pair->remote_candidate().network_id(),
609 last_sent_packet_id); 610 last_sent_packet_id);
610 } 611 }
611 invoker_.AsyncInvoke<void>( 612 invoker_.AsyncInvoke<void>(
612 worker_thread_, Bind(&MediaChannel::OnNetworkRouteChanged, media_channel_, 613 worker_thread_, Bind(&MediaChannel::OnNetworkRouteChanged, media_channel_,
613 transport_name, network_route)); 614 transport_name, network_route));
614 } 615 }
615 616
616 void BaseChannel::SetReadyToSend(bool rtcp, bool ready) { 617 void BaseChannel::SetReadyToSend(bool rtcp, bool ready) {
(...skipping 1790 matching lines...) Expand 10 before | Expand all | Expand 10 after
2407 return data_channel_type_ == DCT_RTP && BaseChannel::ShouldSetupDtlsSrtp_n(); 2408 return data_channel_type_ == DCT_RTP && BaseChannel::ShouldSetupDtlsSrtp_n();
2408 } 2409 }
2409 2410
2410 void DataChannel::OnStreamClosedRemotely(uint32_t sid) { 2411 void DataChannel::OnStreamClosedRemotely(uint32_t sid) {
2411 rtc::TypedMessageData<uint32_t>* message = 2412 rtc::TypedMessageData<uint32_t>* message =
2412 new rtc::TypedMessageData<uint32_t>(sid); 2413 new rtc::TypedMessageData<uint32_t>(sid);
2413 signaling_thread()->Post(this, MSG_STREAMCLOSEDREMOTELY, message); 2414 signaling_thread()->Post(this, MSG_STREAMCLOSEDREMOTELY, message);
2414 } 2415 }
2415 2416
2416 } // namespace cricket 2417 } // namespace cricket
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698