| 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 325 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 336 retransmission, packet_counter_++)); | 336 retransmission, packet_counter_++)); |
| 337 } | 337 } |
| 338 | 338 |
| 339 int64_t PacedSender::ExpectedQueueTimeMs() const { | 339 int64_t PacedSender::ExpectedQueueTimeMs() const { |
| 340 CriticalSectionScoped cs(critsect_.get()); | 340 CriticalSectionScoped cs(critsect_.get()); |
| 341 RTC_DCHECK_GT(pacing_bitrate_kbps_, 0u); | 341 RTC_DCHECK_GT(pacing_bitrate_kbps_, 0u); |
| 342 return static_cast<int64_t>(packets_->SizeInBytes() * 8 / | 342 return static_cast<int64_t>(packets_->SizeInBytes() * 8 / |
| 343 pacing_bitrate_kbps_); | 343 pacing_bitrate_kbps_); |
| 344 } | 344 } |
| 345 | 345 |
| 346 bool PacedSender::InApplicationLimitedRegion() const { | 346 int64_t PacedSender::GetApplicationLimitedRegionStartTime() const { |
| 347 CriticalSectionScoped cs(critsect_.get()); | 347 CriticalSectionScoped cs(critsect_.get()); |
| 348 return alr_detector_->InApplicationLimitedRegion(); | 348 return alr_detector_->GetApplicationLimitedRegionStartTime(); |
| 349 } | 349 } |
| 350 | 350 |
| 351 size_t PacedSender::QueueSizePackets() const { | 351 size_t PacedSender::QueueSizePackets() const { |
| 352 CriticalSectionScoped cs(critsect_.get()); | 352 CriticalSectionScoped cs(critsect_.get()); |
| 353 return packets_->SizeInPackets(); | 353 return packets_->SizeInPackets(); |
| 354 } | 354 } |
| 355 | 355 |
| 356 int64_t PacedSender::QueueInMs() const { | 356 int64_t PacedSender::QueueInMs() const { |
| 357 CriticalSectionScoped cs(critsect_.get()); | 357 CriticalSectionScoped cs(critsect_.get()); |
| 358 | 358 |
| (...skipping 141 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 500 void PacedSender::UpdateBudgetWithElapsedTime(int64_t delta_time_ms) { | 500 void PacedSender::UpdateBudgetWithElapsedTime(int64_t delta_time_ms) { |
| 501 media_budget_->IncreaseBudget(delta_time_ms); | 501 media_budget_->IncreaseBudget(delta_time_ms); |
| 502 padding_budget_->IncreaseBudget(delta_time_ms); | 502 padding_budget_->IncreaseBudget(delta_time_ms); |
| 503 } | 503 } |
| 504 | 504 |
| 505 void PacedSender::UpdateBudgetWithBytesSent(size_t bytes_sent) { | 505 void PacedSender::UpdateBudgetWithBytesSent(size_t bytes_sent) { |
| 506 media_budget_->UseBudget(bytes_sent); | 506 media_budget_->UseBudget(bytes_sent); |
| 507 padding_budget_->UseBudget(bytes_sent); | 507 padding_budget_->UseBudget(bytes_sent); |
| 508 } | 508 } |
| 509 } // namespace webrtc | 509 } // namespace webrtc |
| OLD | NEW |