OLD | NEW |
---|---|
1 /* | 1 /* |
2 * Copyright (c) 2012 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2012 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 456 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... | |
467 } | 467 } |
468 } | 468 } |
469 | 469 |
470 void ChannelGroup::OnNetworkChanged(uint32_t target_bitrate_bps, | 470 void ChannelGroup::OnNetworkChanged(uint32_t target_bitrate_bps, |
471 uint8_t fraction_loss, | 471 uint8_t fraction_loss, |
472 int64_t rtt) { | 472 int64_t rtt) { |
473 bitrate_allocator_->OnNetworkChanged(target_bitrate_bps, fraction_loss, rtt); | 473 bitrate_allocator_->OnNetworkChanged(target_bitrate_bps, fraction_loss, rtt); |
474 int pad_up_to_bitrate_bps = 0; | 474 int pad_up_to_bitrate_bps = 0; |
475 { | 475 { |
476 CriticalSectionScoped lock(encoder_map_cs_.get()); | 476 CriticalSectionScoped lock(encoder_map_cs_.get()); |
477 for (const auto& encoder : send_encoders_) { | 477 for (const auto& encoder : send_encoders_) { |
pbos-webrtc
2015/07/15 10:53:35
remove {}s
stefan-webrtc
2015/07/15 10:54:52
Done.
| |
478 pad_up_to_bitrate_bps += | 478 pad_up_to_bitrate_bps += encoder.second->GetPaddingNeededBps(); |
479 encoder.second->GetPaddingNeededBps(target_bitrate_bps); | |
480 } | 479 } |
481 } | 480 } |
482 pacer_->UpdateBitrate( | 481 pacer_->UpdateBitrate( |
483 target_bitrate_bps / 1000, | 482 target_bitrate_bps / 1000, |
484 PacedSender::kDefaultPaceMultiplier * target_bitrate_bps / 1000, | 483 PacedSender::kDefaultPaceMultiplier * target_bitrate_bps / 1000, |
485 pad_up_to_bitrate_bps / 1000); | 484 pad_up_to_bitrate_bps / 1000); |
486 } | 485 } |
487 } // namespace webrtc | 486 } // namespace webrtc |
OLD | NEW |