| 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 84 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 95 jitter_buffer_.Start(); | 95 jitter_buffer_.Start(); |
| 96 } else { | 96 } else { |
| 97 jitter_buffer_.Flush(); | 97 jitter_buffer_.Flush(); |
| 98 } | 98 } |
| 99 } | 99 } |
| 100 | 100 |
| 101 void VCMReceiver::UpdateRtt(int64_t rtt) { | 101 void VCMReceiver::UpdateRtt(int64_t rtt) { |
| 102 jitter_buffer_.UpdateRtt(rtt); | 102 jitter_buffer_.UpdateRtt(rtt); |
| 103 } | 103 } |
| 104 | 104 |
| 105 int64_t VCMReceiver::TimeUntilNextProcess() { | |
| 106 return jitter_buffer_.TimeUntilNextProcess(); | |
| 107 } | |
| 108 | |
| 109 void VCMReceiver::Process() { | |
| 110 jitter_buffer_.Process(); | |
| 111 } | |
| 112 | |
| 113 int32_t VCMReceiver::InsertPacket(const VCMPacket& packet) { | 105 int32_t VCMReceiver::InsertPacket(const VCMPacket& packet) { |
| 114 // Insert the packet into the jitter buffer. The packet can either be empty or | 106 // Insert the packet into the jitter buffer. The packet can either be empty or |
| 115 // contain media at this point. | 107 // contain media at this point. |
| 116 bool retransmitted = false; | 108 bool retransmitted = false; |
| 117 const VCMFrameBufferEnum ret = | 109 const VCMFrameBufferEnum ret = |
| 118 jitter_buffer_.InsertPacket(packet, &retransmitted); | 110 jitter_buffer_.InsertPacket(packet, &retransmitted); |
| 119 if (ret == kOldPacket) { | 111 if (ret == kOldPacket) { |
| 120 return VCM_OK; | 112 return VCM_OK; |
| 121 } else if (ret == kFlushIndicator) { | 113 } else if (ret == kFlushIndicator) { |
| 122 return VCM_FLUSH_INDICATOR; | 114 return VCM_FLUSH_INDICATOR; |
| (...skipping 171 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 294 timing_->set_min_playout_delay(desired_delay_ms); | 286 timing_->set_min_playout_delay(desired_delay_ms); |
| 295 return 0; | 287 return 0; |
| 296 } | 288 } |
| 297 | 289 |
| 298 void VCMReceiver::RegisterStatsCallback( | 290 void VCMReceiver::RegisterStatsCallback( |
| 299 VCMReceiveStatisticsCallback* callback) { | 291 VCMReceiveStatisticsCallback* callback) { |
| 300 jitter_buffer_.RegisterStatsCallback(callback); | 292 jitter_buffer_.RegisterStatsCallback(callback); |
| 301 } | 293 } |
| 302 | 294 |
| 303 } // namespace webrtc | 295 } // namespace webrtc |
| OLD | NEW |