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

Side by Side Diff: webrtc/media/engine/webrtcvideoengine2.cc

Issue 1803063004: Reset the BWE when the network changes (Closed) Base URL: https://chromium.googlesource.com/external/webrtc@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
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 1333 matching lines...) Expand 10 before | Expand all | Expand 10 after
1344 webrtc::MediaType::VIDEO, 1344 webrtc::MediaType::VIDEO,
1345 reinterpret_cast<const uint8_t*>(packet->data()), packet->size(), 1345 reinterpret_cast<const uint8_t*>(packet->data()), packet->size(),
1346 webrtc_packet_time); 1346 webrtc_packet_time);
1347 } 1347 }
1348 1348
1349 void WebRtcVideoChannel2::OnReadyToSend(bool ready) { 1349 void WebRtcVideoChannel2::OnReadyToSend(bool ready) {
1350 LOG(LS_VERBOSE) << "OnReadyToSend: " << (ready ? "Ready." : "Not ready."); 1350 LOG(LS_VERBOSE) << "OnReadyToSend: " << (ready ? "Ready." : "Not ready.");
1351 call_->SignalNetworkState(ready ? webrtc::kNetworkUp : webrtc::kNetworkDown); 1351 call_->SignalNetworkState(ready ? webrtc::kNetworkUp : webrtc::kNetworkDown);
1352 } 1352 }
1353 1353
1354 void WebRtcVideoChannel2::OnBestConnectionChanged(Connection* connection) {
1355 call_->OnBestConnectionChanged(connection);
1356 }
1357
1354 bool WebRtcVideoChannel2::MuteStream(uint32_t ssrc, bool mute) { 1358 bool WebRtcVideoChannel2::MuteStream(uint32_t ssrc, bool mute) {
1355 LOG(LS_VERBOSE) << "MuteStream: " << ssrc << " -> " 1359 LOG(LS_VERBOSE) << "MuteStream: " << ssrc << " -> "
1356 << (mute ? "mute" : "unmute"); 1360 << (mute ? "mute" : "unmute");
1357 RTC_DCHECK(ssrc != 0); 1361 RTC_DCHECK(ssrc != 0);
1358 rtc::CritScope stream_lock(&stream_crit_); 1362 rtc::CritScope stream_lock(&stream_crit_);
1359 const auto& kv = send_streams_.find(ssrc); 1363 const auto& kv = send_streams_.find(ssrc);
1360 if (kv == send_streams_.end()) { 1364 if (kv == send_streams_.end()) {
1361 LOG(LS_ERROR) << "No sending stream on ssrc " << ssrc; 1365 LOG(LS_ERROR) << "No sending stream on ssrc " << ssrc;
1362 return false; 1366 return false;
1363 } 1367 }
(...skipping 1153 matching lines...) Expand 10 before | Expand all | Expand 10 after
2517 rtx_mapping[video_codecs[i].codec.id] != 2521 rtx_mapping[video_codecs[i].codec.id] !=
2518 fec_settings.red_payload_type) { 2522 fec_settings.red_payload_type) {
2519 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; 2523 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id];
2520 } 2524 }
2521 } 2525 }
2522 2526
2523 return video_codecs; 2527 return video_codecs;
2524 } 2528 }
2525 2529
2526 } // namespace cricket 2530 } // namespace cricket
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698