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

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

Issue 1226093010: Nuke buffered latency mode. It's not actually working, and it's not used. It's just dead code com… (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 5 years, 5 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 * libjingle 2 * libjingle
3 * Copyright 2014 Google Inc. 3 * Copyright 2014 Google Inc.
4 * 4 *
5 * Redistribution and use in source and binary forms, with or without 5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions are met: 6 * modification, are permitted provided that the following conditions are met:
7 * 7 *
8 * 1. Redistributions of source code must retain the above copyright notice, 8 * 1. Redistributions of source code must retain the above copyright notice,
9 * this list of conditions and the following disclaimer. 9 * this list of conditions and the following disclaimer.
10 * 2. Redistributions in binary form must reproduce the above copyright notice, 10 * 2. Redistributions in binary form must reproduce the above copyright notice,
(...skipping 1516 matching lines...) Expand 10 before | Expand all | Expand 10 after
1527 for (auto& kv : send_streams_) 1527 for (auto& kv : send_streams_)
1528 kv.second->SetMaxBitrateBps(max_bitrate_bps); 1528 kv.second->SetMaxBitrateBps(max_bitrate_bps);
1529 return true; 1529 return true;
1530 } 1530 }
1531 1531
1532 bool WebRtcVideoChannel2::SetOptions(const VideoOptions& options) { 1532 bool WebRtcVideoChannel2::SetOptions(const VideoOptions& options) {
1533 TRACE_EVENT0("webrtc", "WebRtcVideoChannel2::SetOptions"); 1533 TRACE_EVENT0("webrtc", "WebRtcVideoChannel2::SetOptions");
1534 LOG(LS_INFO) << "SetOptions: " << options.ToString(); 1534 LOG(LS_INFO) << "SetOptions: " << options.ToString();
1535 VideoOptions old_options = options_; 1535 VideoOptions old_options = options_;
1536 options_.SetAll(options); 1536 options_.SetAll(options);
1537 if (options_ == old_options) { 1537
1538 if (options_ == old_options && options_set_) {
1538 // No new options to set. 1539 // No new options to set.
1539 return true; 1540 return true;
1540 } 1541 }
1541 { 1542 {
1542 rtc::CritScope lock(&capturer_crit_); 1543 rtc::CritScope lock(&capturer_crit_);
1543 options_.cpu_overuse_detection.Get(&signal_cpu_adaptation_); 1544 options_.cpu_overuse_detection.Get(&signal_cpu_adaptation_);
1544 } 1545 }
1546
1545 rtc::DiffServCodePoint dscp = options_.dscp.GetWithDefaultIfUnset(false) 1547 rtc::DiffServCodePoint dscp = options_.dscp.GetWithDefaultIfUnset(false)
1546 ? rtc::DSCP_AF41 1548 ? rtc::DSCP_AF41
1547 : rtc::DSCP_DEFAULT; 1549 : rtc::DSCP_DEFAULT;
1548 MediaChannel::SetDscp(dscp); 1550 MediaChannel::SetDscp(dscp);
1551
1549 rtc::CritScope stream_lock(&stream_crit_); 1552 rtc::CritScope stream_lock(&stream_crit_);
1550 for (std::map<uint32, WebRtcVideoSendStream*>::iterator it = 1553 for (std::map<uint32, WebRtcVideoSendStream*>::iterator it =
1551 send_streams_.begin(); 1554 send_streams_.begin();
1552 it != send_streams_.end(); 1555 it != send_streams_.end();
1553 ++it) { 1556 ++it) {
1554 it->second->SetOptions(options_); 1557 it->second->SetOptions(options_);
1555 } 1558 }
1559 options_set_ = true;
1556 return true; 1560 return true;
1557 } 1561 }
1558 1562
1559 void WebRtcVideoChannel2::SetInterface(NetworkInterface* iface) { 1563 void WebRtcVideoChannel2::SetInterface(NetworkInterface* iface) {
1560 MediaChannel::SetInterface(iface); 1564 MediaChannel::SetInterface(iface);
1561 // Set the RTP recv/send buffer to a bigger size 1565 // Set the RTP recv/send buffer to a bigger size
1562 MediaChannel::SetOption(NetworkInterface::ST_RTP, 1566 MediaChannel::SetOption(NetworkInterface::ST_RTP,
1563 rtc::Socket::OPT_RCVBUF, 1567 rtc::Socket::OPT_RCVBUF,
1564 kVideoRtpBufferSize); 1568 kVideoRtpBufferSize);
1565 1569
(...skipping 1044 matching lines...) Expand 10 before | Expand all | Expand 10 after
2610 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; 2614 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id];
2611 } 2615 }
2612 } 2616 }
2613 2617
2614 return video_codecs; 2618 return video_codecs;
2615 } 2619 }
2616 2620
2617 } // namespace cricket 2621 } // namespace cricket
2618 2622
2619 #endif // HAVE_WEBRTC_VIDEO 2623 #endif // HAVE_WEBRTC_VIDEO
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698