| OLD | NEW |
| 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 247 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 258 last_remb_bps_ / 8 * (now_ms - interval_start_ms_) / 1000; | 258 last_remb_bps_ / 8 * (now_ms - interval_start_ms_) / 1000; |
| 259 } | 259 } |
| 260 EvolveTestState(average_rate_bps); | 260 EvolveTestState(average_rate_bps); |
| 261 interval_start_ms_ = now_ms; | 261 interval_start_ms_ = now_ms; |
| 262 sent_bytes_ = 0; | 262 sent_bytes_ = 0; |
| 263 } | 263 } |
| 264 return test::DirectTransport::SendRtp(data, length); | 264 return test::DirectTransport::SendRtp(data, length); |
| 265 } | 265 } |
| 266 | 266 |
| 267 PacketReceiver::DeliveryStatus LowRateStreamObserver::DeliverPacket( | 267 PacketReceiver::DeliveryStatus LowRateStreamObserver::DeliverPacket( |
| 268 MediaType media_type, const uint8_t* packet, size_t length) { | 268 MediaType media_type, |
| 269 const uint8_t* packet, |
| 270 size_t length, |
| 271 const PacketTime& packet_time) { |
| 269 rtc::CritScope lock(&crit_); | 272 rtc::CritScope lock(&crit_); |
| 270 RTPHeader header; | 273 RTPHeader header; |
| 271 EXPECT_TRUE(rtp_parser_->Parse(packet, length, &header)); | 274 EXPECT_TRUE(rtp_parser_->Parse(packet, length, &header)); |
| 272 receive_stats_->IncomingPacket(header, length, false); | 275 receive_stats_->IncomingPacket(header, length, false); |
| 273 remote_bitrate_estimator_->IncomingPacket( | 276 remote_bitrate_estimator_->IncomingPacket( |
| 274 clock_->TimeInMilliseconds(), length - header.headerLength, header, true); | 277 clock_->TimeInMilliseconds(), length - header.headerLength, header, true); |
| 275 if (remote_bitrate_estimator_->TimeUntilNextProcess() <= 0) { | 278 if (remote_bitrate_estimator_->TimeUntilNextProcess() <= 0) { |
| 276 remote_bitrate_estimator_->Process(); | 279 remote_bitrate_estimator_->Process(); |
| 277 } | 280 } |
| 278 suspended_in_stats_ = send_stream_->GetStats().suspended; | 281 suspended_in_stats_ = send_stream_->GetStats().suspended; |
| (...skipping 275 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 554 | 557 |
| 555 TEST_F(RampUpTest, AbsSendTimeSimulcastByRedWithRtx) { | 558 TEST_F(RampUpTest, AbsSendTimeSimulcastByRedWithRtx) { |
| 556 RunRampUpTest(3, 0, RtpExtension::kAbsSendTime, true, true); | 559 RunRampUpTest(3, 0, RtpExtension::kAbsSendTime, true, true); |
| 557 } | 560 } |
| 558 | 561 |
| 559 TEST_F(RampUpTest, AbsSendTimeSingleStreamWithHighStartBitrate) { | 562 TEST_F(RampUpTest, AbsSendTimeSingleStreamWithHighStartBitrate) { |
| 560 RunRampUpTest(1, 0.9 * kSingleStreamTargetBps, RtpExtension::kAbsSendTime, | 563 RunRampUpTest(1, 0.9 * kSingleStreamTargetBps, RtpExtension::kAbsSendTime, |
| 561 false, false); | 564 false, false); |
| 562 } | 565 } |
| 563 } // namespace webrtc | 566 } // namespace webrtc |
| OLD | NEW |