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

Side by Side Diff: webrtc/audio/audio_receive_stream_unittest.cc

Issue 2064523002: GN: Add video_engine_tests (Closed) Base URL: https://chromium.googlesource.com/external/webrtc.git@master
Patch Set: audio_receive_stream_unittest compile Created 4 years, 6 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) 2015 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2015 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 162 matching lines...) Expand 10 before | Expand all | Expand 10 after
173 size_t value_length) { 173 size_t value_length) {
174 const uint16_t kRtpOneByteHeaderExtensionId = 0xBEDE; 174 const uint16_t kRtpOneByteHeaderExtensionId = 0xBEDE;
175 ByteWriter<uint16_t>::WriteBigEndian(&(*it), kRtpOneByteHeaderExtensionId); 175 ByteWriter<uint16_t>::WriteBigEndian(&(*it), kRtpOneByteHeaderExtensionId);
176 it += 2; 176 it += 2;
177 177
178 ByteWriter<uint16_t>::WriteBigEndian(&(*it), kOneByteExtensionLength / 4); 178 ByteWriter<uint16_t>::WriteBigEndian(&(*it), kOneByteExtensionLength / 4);
179 it += 2; 179 it += 2;
180 const size_t kExtensionDataLength = kOneByteExtensionLength - 1; 180 const size_t kExtensionDataLength = kOneByteExtensionLength - 1;
181 uint32_t shifted_value = extension_value 181 uint32_t shifted_value = extension_value
182 << (8 * (kExtensionDataLength - value_length)); 182 << (8 * (kExtensionDataLength - value_length));
183 *it = (id << 4) + (value_length - 1); 183 *it = (id << 4) + (static_cast<uint8_t>(value_length) - 1);
184 ++it; 184 ++it;
185 ByteWriter<uint32_t, kExtensionDataLength>::WriteBigEndian(&(*it), 185 ByteWriter<uint32_t, kExtensionDataLength>::WriteBigEndian(&(*it),
186 shifted_value); 186 shifted_value);
187 } 187 }
188 188
189 const std::vector<uint8_t> CreateRtpHeaderWithOneByteExtension( 189 const std::vector<uint8_t> CreateRtpHeaderWithOneByteExtension(
190 int extension_id, 190 int extension_id,
191 uint32_t extension_value, 191 uint32_t extension_value,
192 size_t value_length) { 192 size_t value_length) {
193 std::vector<uint8_t> header; 193 std::vector<uint8_t> header;
(...skipping 137 matching lines...) Expand 10 before | Expand all | Expand 10 after
331 EXPECT_EQ(kAudioDecodeStats.calls_to_neteq, stats.decoding_calls_to_neteq); 331 EXPECT_EQ(kAudioDecodeStats.calls_to_neteq, stats.decoding_calls_to_neteq);
332 EXPECT_EQ(kAudioDecodeStats.decoded_normal, stats.decoding_normal); 332 EXPECT_EQ(kAudioDecodeStats.decoded_normal, stats.decoding_normal);
333 EXPECT_EQ(kAudioDecodeStats.decoded_plc, stats.decoding_plc); 333 EXPECT_EQ(kAudioDecodeStats.decoded_plc, stats.decoding_plc);
334 EXPECT_EQ(kAudioDecodeStats.decoded_cng, stats.decoding_cng); 334 EXPECT_EQ(kAudioDecodeStats.decoded_cng, stats.decoding_cng);
335 EXPECT_EQ(kAudioDecodeStats.decoded_plc_cng, stats.decoding_plc_cng); 335 EXPECT_EQ(kAudioDecodeStats.decoded_plc_cng, stats.decoding_plc_cng);
336 EXPECT_EQ(kCallStats.capture_start_ntp_time_ms_, 336 EXPECT_EQ(kCallStats.capture_start_ntp_time_ms_,
337 stats.capture_start_ntp_time_ms); 337 stats.capture_start_ntp_time_ms);
338 } 338 }
339 } // namespace test 339 } // namespace test
340 } // namespace webrtc 340 } // namespace webrtc
OLDNEW
« no previous file with comments | « webrtc/audio/BUILD.gn ('k') | webrtc/call/BUILD.gn » ('j') | webrtc/test/BUILD.gn » ('J')

Powered by Google App Engine
This is Rietveld 408576698