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

Side by Side Diff: webrtc/modules/audio_coding/neteq/tools/neteq_replacement_input.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) 2016 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2016 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 52 matching lines...) Expand 10 before | Expand all | Expand 10 after
63 void NetEqReplacementInput::ReplacePacket() { 63 void NetEqReplacementInput::ReplacePacket() {
64 if (!source_->NextPacketTime()) { 64 if (!source_->NextPacketTime()) {
65 // End of input. Cannot do proper replacement on the very last packet, so we 65 // End of input. Cannot do proper replacement on the very last packet, so we
66 // delete it instead. 66 // delete it instead.
67 packet_.reset(); 67 packet_.reset();
68 return; 68 return;
69 } 69 }
70 70
71 RTC_DCHECK(packet_); 71 RTC_DCHECK(packet_);
72 72
73 RTC_CHECK_EQ(forbidden_types_.count(packet_->header.header.payloadType), 0u) 73 RTC_CHECK_EQ(forbidden_types_.count(packet_->header.header.payloadType), 0)
74 << "Payload type " << static_cast<int>(packet_->header.header.payloadType) 74 << "Payload type " << static_cast<int>(packet_->header.header.payloadType)
75 << " is forbidden."; 75 << " is forbidden.";
76 76
77 // Check if this packet is comfort noise. 77 // Check if this packet is comfort noise.
78 if (comfort_noise_types_.count(packet_->header.header.payloadType) != 0) { 78 if (comfort_noise_types_.count(packet_->header.header.payloadType) != 0) {
79 // If CNG, simply insert a zero-energy one-byte payload. 79 // If CNG, simply insert a zero-energy one-byte payload.
80 uint8_t cng_payload[1] = {127}; // Max attenuation of CNG. 80 uint8_t cng_payload[1] = {127}; // Max attenuation of CNG.
81 packet_->payload.SetData(cng_payload); 81 packet_->payload.SetData(cng_payload);
82 return; 82 return;
83 } 83 }
(...skipping 11 matching lines...) Expand all
95 FakeDecodeFromFile::PrepareEncoded(packet_->header.header.timestamp, 95 FakeDecodeFromFile::PrepareEncoded(packet_->header.header.timestamp,
96 input_frame_size_timestamps, 96 input_frame_size_timestamps,
97 packet_->payload.size(), payload); 97 packet_->payload.size(), payload);
98 packet_->payload.SetData(payload); 98 packet_->payload.SetData(payload);
99 packet_->header.header.payloadType = replacement_payload_type_; 99 packet_->header.header.payloadType = replacement_payload_type_;
100 return; 100 return;
101 } 101 }
102 102
103 } // namespace test 103 } // namespace test
104 } // namespace webrtc 104 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698