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

Side by Side Diff: webrtc/modules/audio_coding/neteq/nack_tracker.cc

Issue 2535593002: RTC_[D]CHECK_op: Remove "u" suffix on integer constants (Closed)
Patch Set: Created 4 years 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) 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 178 matching lines...) Expand 10 before | Expand all | Expand 10 after
189 timestamp_last_received_rtp_ = 0; 189 timestamp_last_received_rtp_ = 0;
190 any_rtp_received_ = false; 190 any_rtp_received_ = false;
191 sequence_num_last_decoded_rtp_ = 0; 191 sequence_num_last_decoded_rtp_ = 0;
192 timestamp_last_decoded_rtp_ = 0; 192 timestamp_last_decoded_rtp_ = 0;
193 any_rtp_decoded_ = false; 193 any_rtp_decoded_ = false;
194 sample_rate_khz_ = kDefaultSampleRateKhz; 194 sample_rate_khz_ = kDefaultSampleRateKhz;
195 samples_per_packet_ = sample_rate_khz_ * kDefaultPacketSizeMs; 195 samples_per_packet_ = sample_rate_khz_ * kDefaultPacketSizeMs;
196 } 196 }
197 197
198 void NackTracker::SetMaxNackListSize(size_t max_nack_list_size) { 198 void NackTracker::SetMaxNackListSize(size_t max_nack_list_size) {
199 RTC_CHECK_GT(max_nack_list_size, 0u); 199 RTC_CHECK_GT(max_nack_list_size, 0);
200 // Ugly hack to get around the problem of passing static consts by reference. 200 // Ugly hack to get around the problem of passing static consts by reference.
201 const size_t kNackListSizeLimitLocal = NackTracker::kNackListSizeLimit; 201 const size_t kNackListSizeLimitLocal = NackTracker::kNackListSizeLimit;
202 RTC_CHECK_LE(max_nack_list_size, kNackListSizeLimitLocal); 202 RTC_CHECK_LE(max_nack_list_size, kNackListSizeLimitLocal);
203 203
204 max_nack_list_size_ = max_nack_list_size; 204 max_nack_list_size_ = max_nack_list_size;
205 LimitNackListSize(); 205 LimitNackListSize();
206 } 206 }
207 207
208 void NackTracker::LimitNackListSize() { 208 void NackTracker::LimitNackListSize() {
209 uint16_t limit = sequence_num_last_received_rtp_ - 209 uint16_t limit = sequence_num_last_received_rtp_ -
(...skipping 14 matching lines...) Expand all
224 for (NackList::const_iterator it = nack_list_.begin(); it != nack_list_.end(); 224 for (NackList::const_iterator it = nack_list_.begin(); it != nack_list_.end();
225 ++it) { 225 ++it) {
226 if (it->second.is_missing && 226 if (it->second.is_missing &&
227 it->second.time_to_play_ms > round_trip_time_ms) 227 it->second.time_to_play_ms > round_trip_time_ms)
228 sequence_numbers.push_back(it->first); 228 sequence_numbers.push_back(it->first);
229 } 229 }
230 return sequence_numbers; 230 return sequence_numbers;
231 } 231 }
232 232
233 } // namespace webrtc 233 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/modules/audio_coding/neteq/delay_peak_detector.cc ('k') | webrtc/modules/audio_coding/neteq/test/RTPencode.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698