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

Side by Side Diff: webrtc/modules/audio_coding/neteq/tools/neteq_quality_test.cc

Issue 2807273004: Change NetEq::InsertPacket to take an RTPHeader (Closed)
Patch Set: git cl format Created 3 years, 8 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) 2014 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2014 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 362 matching lines...) Expand 10 before | Expand all | Expand 10 after
373 rtp_generator_->GetRtpHeader(kPayloadType, in_size_samples_, 373 rtp_generator_->GetRtpHeader(kPayloadType, in_size_samples_,
374 &rtp_header_); 374 &rtp_header_);
375 Log() << "Packet of size " 375 Log() << "Packet of size "
376 << payload_size_bytes_ 376 << payload_size_bytes_
377 << " bytes, for frame at " 377 << " bytes, for frame at "
378 << packet_input_time_ms 378 << packet_input_time_ms
379 << " ms "; 379 << " ms ";
380 if (payload_size_bytes_ > 0) { 380 if (payload_size_bytes_ > 0) {
381 if (!PacketLost()) { 381 if (!PacketLost()) {
382 int ret = neteq_->InsertPacket( 382 int ret = neteq_->InsertPacket(
383 rtp_header_, 383 rtp_header_.header,
384 rtc::ArrayView<const uint8_t>(payload_.data(), payload_size_bytes_), 384 rtc::ArrayView<const uint8_t>(payload_.data(), payload_size_bytes_),
385 packet_input_time_ms * in_sampling_khz_); 385 packet_input_time_ms * in_sampling_khz_);
386 if (ret != NetEq::kOK) 386 if (ret != NetEq::kOK)
387 return -1; 387 return -1;
388 Log() << "was sent."; 388 Log() << "was sent.";
389 } else { 389 } else {
390 Log() << "was lost."; 390 Log() << "was lost.";
391 } 391 }
392 } 392 }
393 Log() << std::endl; 393 Log() << std::endl;
(...skipping 38 matching lines...) Expand 10 before | Expand all | Expand 10 after
432 } 432 }
433 } 433 }
434 Log() << "Average bit rate was " 434 Log() << "Average bit rate was "
435 << 8.0f * total_payload_size_bytes_ / FLAGS_runtime_ms 435 << 8.0f * total_payload_size_bytes_ / FLAGS_runtime_ms
436 << " kbps" 436 << " kbps"
437 << std::endl; 437 << std::endl;
438 } 438 }
439 439
440 } // namespace test 440 } // namespace test
441 } // namespace webrtc 441 } // namespace webrtc
OLDNEW

Powered by Google App Engine
This is Rietveld 408576698