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

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

Issue 1642513002: Delete unused members from VideoOptions (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Suggested comment edits. Created 4 years, 10 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 618 matching lines...) Expand 10 before | Expand all | Expand 10 after
629 rtcp_receiver_report_ssrc_ = kDefaultRtcpReceiverReportSsrc; 629 rtcp_receiver_report_ssrc_ = kDefaultRtcpReceiverReportSsrc;
630 sending_ = false; 630 sending_ = false;
631 default_send_ssrc_ = 0; 631 default_send_ssrc_ = 0;
632 SetRecvCodecs(recv_codecs); 632 SetRecvCodecs(recv_codecs);
633 } 633 }
634 634
635 void WebRtcVideoChannel2::SetDefaultOptions() { 635 void WebRtcVideoChannel2::SetDefaultOptions() {
636 options_.cpu_overuse_detection = rtc::Optional<bool>(true); 636 options_.cpu_overuse_detection = rtc::Optional<bool>(true);
637 options_.dscp = rtc::Optional<bool>(false); 637 options_.dscp = rtc::Optional<bool>(false);
638 options_.suspend_below_min_bitrate = rtc::Optional<bool>(false); 638 options_.suspend_below_min_bitrate = rtc::Optional<bool>(false);
639 options_.screencast_min_bitrate = rtc::Optional<int>(0); 639 options_.screencast_min_bitrate_kbps = rtc::Optional<int>(0);
640 } 640 }
641 641
642 WebRtcVideoChannel2::~WebRtcVideoChannel2() { 642 WebRtcVideoChannel2::~WebRtcVideoChannel2() {
643 for (auto& kv : send_streams_) 643 for (auto& kv : send_streams_)
644 delete kv.second; 644 delete kv.second;
645 for (auto& kv : receive_streams_) 645 for (auto& kv : receive_streams_)
646 delete kv.second; 646 delete kv.second;
647 } 647 }
648 648
649 bool WebRtcVideoChannel2::CodecIsExternallySupported( 649 bool WebRtcVideoChannel2::CodecIsExternallySupported(
(...skipping 1290 matching lines...) Expand 10 before | Expand all | Expand 10 after
1940 RecreateWebRtcStream(); 1940 RecreateWebRtcStream();
1941 } 1941 }
1942 } 1942 }
1943 1943
1944 webrtc::VideoEncoderConfig 1944 webrtc::VideoEncoderConfig
1945 WebRtcVideoChannel2::WebRtcVideoSendStream::CreateVideoEncoderConfig( 1945 WebRtcVideoChannel2::WebRtcVideoSendStream::CreateVideoEncoderConfig(
1946 const Dimensions& dimensions, 1946 const Dimensions& dimensions,
1947 const VideoCodec& codec) const { 1947 const VideoCodec& codec) const {
1948 webrtc::VideoEncoderConfig encoder_config; 1948 webrtc::VideoEncoderConfig encoder_config;
1949 if (dimensions.is_screencast) { 1949 if (dimensions.is_screencast) {
1950 RTC_CHECK(parameters_.options.screencast_min_bitrate); 1950 RTC_CHECK(parameters_.options.screencast_min_bitrate_kbps);
1951 encoder_config.min_transmit_bitrate_bps = 1951 encoder_config.min_transmit_bitrate_bps =
1952 *parameters_.options.screencast_min_bitrate * 1000; 1952 *parameters_.options.screencast_min_bitrate_kbps * 1000;
1953 encoder_config.content_type = 1953 encoder_config.content_type =
1954 webrtc::VideoEncoderConfig::ContentType::kScreen; 1954 webrtc::VideoEncoderConfig::ContentType::kScreen;
1955 } else { 1955 } else {
1956 encoder_config.min_transmit_bitrate_bps = 0; 1956 encoder_config.min_transmit_bitrate_bps = 0;
1957 encoder_config.content_type = 1957 encoder_config.content_type =
1958 webrtc::VideoEncoderConfig::ContentType::kRealtimeVideo; 1958 webrtc::VideoEncoderConfig::ContentType::kRealtimeVideo;
1959 } 1959 }
1960 1960
1961 // Restrict dimensions according to codec max. 1961 // Restrict dimensions according to codec max.
1962 int width = dimensions.width; 1962 int width = dimensions.width;
(...skipping 663 matching lines...) Expand 10 before | Expand all | Expand 10 after
2626 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id]; 2626 video_codecs[i].rtx_payload_type = rtx_mapping[video_codecs[i].codec.id];
2627 } 2627 }
2628 } 2628 }
2629 2629
2630 return video_codecs; 2630 return video_codecs;
2631 } 2631 }
2632 2632
2633 } // namespace cricket 2633 } // namespace cricket
2634 2634
2635 #endif // HAVE_WEBRTC_VIDEO 2635 #endif // HAVE_WEBRTC_VIDEO
OLDNEW
« no previous file with comments | « talk/media/base/videoengine_unittest.h ('k') | talk/media/webrtc/webrtcvideoengine2_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698