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

Side by Side Diff: webrtc/video/video_send_stream.cc

Issue 2035383002: Implementing auto pausing of video streams. (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Removed comment. 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
« no previous file with comments | « webrtc/call/rampup_tests.cc ('k') | webrtc/video/video_send_stream_tests.cc » ('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 542 matching lines...) Expand 10 before | Expand all | Expand 10 after
553 this, encoder_settings->video_codec.minBitrate * 1000, 553 this, encoder_settings->video_codec.minBitrate * 1000,
554 encoder_settings->video_codec.maxBitrate * 1000, 554 encoder_settings->video_codec.maxBitrate * 1000,
555 !config_.suspend_below_min_bitrate) / 555 !config_.suspend_below_min_bitrate) /
556 1000; 556 1000;
557 557
558 payload_router_.SetSendStreams(encoder_settings->streams); 558 payload_router_.SetSendStreams(encoder_settings->streams);
559 vie_encoder_.SetEncoder(encoder_settings->video_codec, 559 vie_encoder_.SetEncoder(encoder_settings->video_codec,
560 encoder_settings->min_transmit_bitrate_bps, 560 encoder_settings->min_transmit_bitrate_bps,
561 payload_router_.MaxPayloadLength()); 561 payload_router_.MaxPayloadLength());
562 562
563 // vie_encoder_.SetEncoder must be called before this.
564 if (config_.suspend_below_min_bitrate)
565 video_sender_->SuspendBelowMinBitrate();
566
567 // Clear stats for disabled layers. 563 // Clear stats for disabled layers.
568 for (size_t i = encoder_settings->streams.size(); 564 for (size_t i = encoder_settings->streams.size();
569 i < config_.rtp.ssrcs.size(); ++i) { 565 i < config_.rtp.ssrcs.size(); ++i) {
570 stats_proxy_.OnInactiveSsrc(config_.rtp.ssrcs[i]); 566 stats_proxy_.OnInactiveSsrc(config_.rtp.ssrcs[i]);
571 } 567 }
572 568
573 size_t number_of_temporal_layers = 569 size_t number_of_temporal_layers =
574 encoder_settings->streams.back() 570 encoder_settings->streams.back()
575 .temporal_layer_thresholds_bps.size() + 571 .temporal_layer_thresholds_bps.size() +
576 1; 572 1;
(...skipping 248 matching lines...) Expand 10 before | Expand all | Expand 10 after
825 &module_nack_rate); 821 &module_nack_rate);
826 *sent_video_rate_bps += module_video_rate; 822 *sent_video_rate_bps += module_video_rate;
827 *sent_nack_rate_bps += module_nack_rate; 823 *sent_nack_rate_bps += module_nack_rate;
828 *sent_fec_rate_bps += module_fec_rate; 824 *sent_fec_rate_bps += module_fec_rate;
829 } 825 }
830 return 0; 826 return 0;
831 } 827 }
832 828
833 } // namespace internal 829 } // namespace internal
834 } // namespace webrtc 830 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/call/rampup_tests.cc ('k') | webrtc/video/video_send_stream_tests.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698