OLD | NEW |
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 373 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
384 Log() << "was sent."; | 384 Log() << "was sent."; |
385 } else { | 385 } else { |
386 Log() << "was lost."; | 386 Log() << "was lost."; |
387 } | 387 } |
388 } | 388 } |
389 Log() << std::endl; | 389 Log() << std::endl; |
390 return packet_input_time_ms; | 390 return packet_input_time_ms; |
391 } | 391 } |
392 | 392 |
393 int NetEqQualityTest::DecodeBlock() { | 393 int NetEqQualityTest::DecodeBlock() { |
394 int ret = neteq_->GetAudio(&out_frame_, NULL); | 394 int ret = neteq_->GetAudio(&out_frame_); |
395 | 395 |
396 if (ret != NetEq::kOK) { | 396 if (ret != NetEq::kOK) { |
397 return -1; | 397 return -1; |
398 } else { | 398 } else { |
399 RTC_DCHECK_EQ(out_frame_.num_channels_, channels_); | 399 RTC_DCHECK_EQ(out_frame_.num_channels_, channels_); |
400 RTC_DCHECK_EQ(out_frame_.samples_per_channel_, | 400 RTC_DCHECK_EQ(out_frame_.samples_per_channel_, |
401 static_cast<size_t>(kOutputSizeMs * out_sampling_khz_)); | 401 static_cast<size_t>(kOutputSizeMs * out_sampling_khz_)); |
402 RTC_CHECK(output_->WriteArray( | 402 RTC_CHECK(output_->WriteArray( |
403 out_frame_.data_, | 403 out_frame_.data_, |
404 out_frame_.samples_per_channel_ * out_frame_.num_channels_)); | 404 out_frame_.samples_per_channel_ * out_frame_.num_channels_)); |
(...skipping 21 matching lines...) Expand all Loading... |
426 } | 426 } |
427 } | 427 } |
428 Log() << "Average bit rate was " | 428 Log() << "Average bit rate was " |
429 << 8.0f * total_payload_size_bytes_ / FLAGS_runtime_ms | 429 << 8.0f * total_payload_size_bytes_ / FLAGS_runtime_ms |
430 << " kbps" | 430 << " kbps" |
431 << std::endl; | 431 << std::endl; |
432 } | 432 } |
433 | 433 |
434 } // namespace test | 434 } // namespace test |
435 } // namespace webrtc | 435 } // namespace webrtc |
OLD | NEW |