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

Side by Side Diff: webrtc/modules/video_coding/jitter_buffer.cc

Issue 1721353002: Replace scoped_ptr with unique_ptr in webrtc/modules/video_coding/ (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: Created 4 years, 10 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
OLDNEW
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 #include "webrtc/modules/video_coding/jitter_buffer.h" 10 #include "webrtc/modules/video_coding/jitter_buffer.h"
(...skipping 197 matching lines...) Expand 10 before | Expand all | Expand 10 after
208 if (Find(frame_it.second->TimeStamp(), &ss_it)) { 208 if (Find(frame_it.second->TimeStamp(), &ss_it)) {
209 if (gof_idx >= ss_it->second.num_frames_in_gof) { 209 if (gof_idx >= ss_it->second.num_frames_in_gof) {
210 continue; // Assume corresponding SS not yet received. 210 continue; // Assume corresponding SS not yet received.
211 } 211 }
212 frame_it.second->SetGofInfo(ss_it->second, gof_idx); 212 frame_it.second->SetGofInfo(ss_it->second, gof_idx);
213 } 213 }
214 } 214 }
215 } 215 }
216 216
217 VCMJitterBuffer::VCMJitterBuffer(Clock* clock, 217 VCMJitterBuffer::VCMJitterBuffer(Clock* clock,
218 rtc::scoped_ptr<EventWrapper> event) 218 std::unique_ptr<EventWrapper> event)
219 : clock_(clock), 219 : clock_(clock),
220 running_(false), 220 running_(false),
221 crit_sect_(CriticalSectionWrapper::CreateCriticalSection()), 221 crit_sect_(CriticalSectionWrapper::CreateCriticalSection()),
222 frame_event_(std::move(event)), 222 frame_event_(std::move(event)),
223 max_number_of_frames_(kStartNumberOfFrames), 223 max_number_of_frames_(kStartNumberOfFrames),
224 free_frames_(), 224 free_frames_(),
225 decodable_frames_(), 225 decodable_frames_(),
226 incomplete_frames_(), 226 incomplete_frames_(),
227 last_decoded_state_(), 227 last_decoded_state_(),
228 first_packet_since_reset_(true), 228 first_packet_since_reset_(true),
(...skipping 1108 matching lines...) Expand 10 before | Expand all | Expand 10 after
1337 } 1337 }
1338 // Evaluate if the RTT is higher than |high_rtt_nack_threshold_ms_|, and in 1338 // Evaluate if the RTT is higher than |high_rtt_nack_threshold_ms_|, and in
1339 // that case we don't wait for retransmissions. 1339 // that case we don't wait for retransmissions.
1340 if (high_rtt_nack_threshold_ms_ >= 0 && 1340 if (high_rtt_nack_threshold_ms_ >= 0 &&
1341 rtt_ms_ >= high_rtt_nack_threshold_ms_) { 1341 rtt_ms_ >= high_rtt_nack_threshold_ms_) {
1342 return false; 1342 return false;
1343 } 1343 }
1344 return true; 1344 return true;
1345 } 1345 }
1346 } // namespace webrtc 1346 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/video_coding/jitter_buffer.h ('k') | webrtc/modules/video_coding/jitter_buffer_unittest.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698