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

Side by Side Diff: webrtc/media/engine/webrtcvoiceengine_unittest.cc

Issue 2503383002: Expose RtpCodecParameters to VoiceMediaInfo stats. (Closed)
Patch Set: Addressed comments, using int Created 4 years, 1 month 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
« no previous file with comments | « webrtc/media/engine/webrtcvoiceengine.cc ('k') | no next file » | no next file with comments »
Toggle Intra-line Diffs ('i') | Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
OLDNEW
1 /* 1 /*
2 * Copyright (c) 2008 The WebRTC project authors. All Rights Reserved. 2 * Copyright (c) 2008 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 426 matching lines...) Expand 10 before | Expand all | Expand 10 after
437 } 437 }
438 438
439 webrtc::AudioSendStream::Stats GetAudioSendStreamStats() const { 439 webrtc::AudioSendStream::Stats GetAudioSendStreamStats() const {
440 webrtc::AudioSendStream::Stats stats; 440 webrtc::AudioSendStream::Stats stats;
441 stats.local_ssrc = 12; 441 stats.local_ssrc = 12;
442 stats.bytes_sent = 345; 442 stats.bytes_sent = 345;
443 stats.packets_sent = 678; 443 stats.packets_sent = 678;
444 stats.packets_lost = 9012; 444 stats.packets_lost = 9012;
445 stats.fraction_lost = 34.56f; 445 stats.fraction_lost = 34.56f;
446 stats.codec_name = "codec_name_send"; 446 stats.codec_name = "codec_name_send";
447 stats.codec_payload_type = rtc::Optional<int>(42);
447 stats.ext_seqnum = 789; 448 stats.ext_seqnum = 789;
448 stats.jitter_ms = 12; 449 stats.jitter_ms = 12;
449 stats.rtt_ms = 345; 450 stats.rtt_ms = 345;
450 stats.audio_level = 678; 451 stats.audio_level = 678;
451 stats.aec_quality_min = 9.01f; 452 stats.aec_quality_min = 9.01f;
452 stats.echo_delay_median_ms = 234; 453 stats.echo_delay_median_ms = 234;
453 stats.echo_delay_std_ms = 567; 454 stats.echo_delay_std_ms = 567;
454 stats.echo_return_loss = 890; 455 stats.echo_return_loss = 890;
455 stats.echo_return_loss_enhancement = 1234; 456 stats.echo_return_loss_enhancement = 1234;
456 stats.residual_echo_likelihood = 0.432f; 457 stats.residual_echo_likelihood = 0.432f;
457 stats.typing_noise_detected = true; 458 stats.typing_noise_detected = true;
458 return stats; 459 return stats;
459 } 460 }
460 void SetAudioSendStreamStats() { 461 void SetAudioSendStreamStats() {
461 for (auto* s : call_.GetAudioSendStreams()) { 462 for (auto* s : call_.GetAudioSendStreams()) {
462 s->SetStats(GetAudioSendStreamStats()); 463 s->SetStats(GetAudioSendStreamStats());
463 } 464 }
464 } 465 }
465 void VerifyVoiceSenderInfo(const cricket::VoiceSenderInfo& info, 466 void VerifyVoiceSenderInfo(const cricket::VoiceSenderInfo& info,
466 bool is_sending) { 467 bool is_sending) {
467 const auto stats = GetAudioSendStreamStats(); 468 const auto stats = GetAudioSendStreamStats();
468 EXPECT_EQ(info.ssrc(), stats.local_ssrc); 469 EXPECT_EQ(info.ssrc(), stats.local_ssrc);
469 EXPECT_EQ(info.bytes_sent, stats.bytes_sent); 470 EXPECT_EQ(info.bytes_sent, stats.bytes_sent);
470 EXPECT_EQ(info.packets_sent, stats.packets_sent); 471 EXPECT_EQ(info.packets_sent, stats.packets_sent);
471 EXPECT_EQ(info.packets_lost, stats.packets_lost); 472 EXPECT_EQ(info.packets_lost, stats.packets_lost);
472 EXPECT_EQ(info.fraction_lost, stats.fraction_lost); 473 EXPECT_EQ(info.fraction_lost, stats.fraction_lost);
473 EXPECT_EQ(info.codec_name, stats.codec_name); 474 EXPECT_EQ(info.codec_name, stats.codec_name);
475 EXPECT_EQ(info.codec_payload_type, stats.codec_payload_type);
474 EXPECT_EQ(info.ext_seqnum, stats.ext_seqnum); 476 EXPECT_EQ(info.ext_seqnum, stats.ext_seqnum);
475 EXPECT_EQ(info.jitter_ms, stats.jitter_ms); 477 EXPECT_EQ(info.jitter_ms, stats.jitter_ms);
476 EXPECT_EQ(info.rtt_ms, stats.rtt_ms); 478 EXPECT_EQ(info.rtt_ms, stats.rtt_ms);
477 EXPECT_EQ(info.audio_level, stats.audio_level); 479 EXPECT_EQ(info.audio_level, stats.audio_level);
478 EXPECT_EQ(info.aec_quality_min, stats.aec_quality_min); 480 EXPECT_EQ(info.aec_quality_min, stats.aec_quality_min);
479 EXPECT_EQ(info.echo_delay_median_ms, stats.echo_delay_median_ms); 481 EXPECT_EQ(info.echo_delay_median_ms, stats.echo_delay_median_ms);
480 EXPECT_EQ(info.echo_delay_std_ms, stats.echo_delay_std_ms); 482 EXPECT_EQ(info.echo_delay_std_ms, stats.echo_delay_std_ms);
481 EXPECT_EQ(info.echo_return_loss, stats.echo_return_loss); 483 EXPECT_EQ(info.echo_return_loss, stats.echo_return_loss);
482 EXPECT_EQ(info.echo_return_loss_enhancement, 484 EXPECT_EQ(info.echo_return_loss_enhancement,
483 stats.echo_return_loss_enhancement); 485 stats.echo_return_loss_enhancement);
484 EXPECT_EQ(info.residual_echo_likelihood, stats.residual_echo_likelihood); 486 EXPECT_EQ(info.residual_echo_likelihood, stats.residual_echo_likelihood);
485 EXPECT_EQ(info.typing_noise_detected, 487 EXPECT_EQ(info.typing_noise_detected,
486 stats.typing_noise_detected && is_sending); 488 stats.typing_noise_detected && is_sending);
487 } 489 }
488 490
489 webrtc::AudioReceiveStream::Stats GetAudioReceiveStreamStats() const { 491 webrtc::AudioReceiveStream::Stats GetAudioReceiveStreamStats() const {
490 webrtc::AudioReceiveStream::Stats stats; 492 webrtc::AudioReceiveStream::Stats stats;
491 stats.remote_ssrc = 123; 493 stats.remote_ssrc = 123;
492 stats.bytes_rcvd = 456; 494 stats.bytes_rcvd = 456;
493 stats.packets_rcvd = 768; 495 stats.packets_rcvd = 768;
494 stats.packets_lost = 101; 496 stats.packets_lost = 101;
495 stats.fraction_lost = 23.45f; 497 stats.fraction_lost = 23.45f;
496 stats.codec_name = "codec_name_recv"; 498 stats.codec_name = "codec_name_recv";
499 stats.codec_payload_type = rtc::Optional<int>(42);
497 stats.ext_seqnum = 678; 500 stats.ext_seqnum = 678;
498 stats.jitter_ms = 901; 501 stats.jitter_ms = 901;
499 stats.jitter_buffer_ms = 234; 502 stats.jitter_buffer_ms = 234;
500 stats.jitter_buffer_preferred_ms = 567; 503 stats.jitter_buffer_preferred_ms = 567;
501 stats.delay_estimate_ms = 890; 504 stats.delay_estimate_ms = 890;
502 stats.audio_level = 1234; 505 stats.audio_level = 1234;
503 stats.expand_rate = 5.67f; 506 stats.expand_rate = 5.67f;
504 stats.speech_expand_rate = 8.90f; 507 stats.speech_expand_rate = 8.90f;
505 stats.secondary_decoded_rate = 1.23f; 508 stats.secondary_decoded_rate = 1.23f;
506 stats.accelerate_rate = 4.56f; 509 stats.accelerate_rate = 4.56f;
(...skipping 14 matching lines...) Expand all
521 } 524 }
522 } 525 }
523 void VerifyVoiceReceiverInfo(const cricket::VoiceReceiverInfo& info) { 526 void VerifyVoiceReceiverInfo(const cricket::VoiceReceiverInfo& info) {
524 const auto stats = GetAudioReceiveStreamStats(); 527 const auto stats = GetAudioReceiveStreamStats();
525 EXPECT_EQ(info.ssrc(), stats.remote_ssrc); 528 EXPECT_EQ(info.ssrc(), stats.remote_ssrc);
526 EXPECT_EQ(info.bytes_rcvd, stats.bytes_rcvd); 529 EXPECT_EQ(info.bytes_rcvd, stats.bytes_rcvd);
527 EXPECT_EQ(info.packets_rcvd, stats.packets_rcvd); 530 EXPECT_EQ(info.packets_rcvd, stats.packets_rcvd);
528 EXPECT_EQ(info.packets_lost, stats.packets_lost); 531 EXPECT_EQ(info.packets_lost, stats.packets_lost);
529 EXPECT_EQ(info.fraction_lost, stats.fraction_lost); 532 EXPECT_EQ(info.fraction_lost, stats.fraction_lost);
530 EXPECT_EQ(info.codec_name, stats.codec_name); 533 EXPECT_EQ(info.codec_name, stats.codec_name);
534 EXPECT_EQ(info.codec_payload_type, stats.codec_payload_type);
531 EXPECT_EQ(info.ext_seqnum, stats.ext_seqnum); 535 EXPECT_EQ(info.ext_seqnum, stats.ext_seqnum);
532 EXPECT_EQ(info.jitter_ms, stats.jitter_ms); 536 EXPECT_EQ(info.jitter_ms, stats.jitter_ms);
533 EXPECT_EQ(info.jitter_buffer_ms, stats.jitter_buffer_ms); 537 EXPECT_EQ(info.jitter_buffer_ms, stats.jitter_buffer_ms);
534 EXPECT_EQ(info.jitter_buffer_preferred_ms, 538 EXPECT_EQ(info.jitter_buffer_preferred_ms,
535 stats.jitter_buffer_preferred_ms); 539 stats.jitter_buffer_preferred_ms);
536 EXPECT_EQ(info.delay_estimate_ms, stats.delay_estimate_ms); 540 EXPECT_EQ(info.delay_estimate_ms, stats.delay_estimate_ms);
537 EXPECT_EQ(info.audio_level, stats.audio_level); 541 EXPECT_EQ(info.audio_level, stats.audio_level);
538 EXPECT_EQ(info.expand_rate, stats.expand_rate); 542 EXPECT_EQ(info.expand_rate, stats.expand_rate);
539 EXPECT_EQ(info.speech_expand_rate, stats.speech_expand_rate); 543 EXPECT_EQ(info.speech_expand_rate, stats.speech_expand_rate);
540 EXPECT_EQ(info.secondary_decoded_rate, stats.secondary_decoded_rate); 544 EXPECT_EQ(info.secondary_decoded_rate, stats.secondary_decoded_rate);
541 EXPECT_EQ(info.accelerate_rate, stats.accelerate_rate); 545 EXPECT_EQ(info.accelerate_rate, stats.accelerate_rate);
542 EXPECT_EQ(info.preemptive_expand_rate, stats.preemptive_expand_rate); 546 EXPECT_EQ(info.preemptive_expand_rate, stats.preemptive_expand_rate);
543 EXPECT_EQ(info.decoding_calls_to_silence_generator, 547 EXPECT_EQ(info.decoding_calls_to_silence_generator,
544 stats.decoding_calls_to_silence_generator); 548 stats.decoding_calls_to_silence_generator);
545 EXPECT_EQ(info.decoding_calls_to_neteq, stats.decoding_calls_to_neteq); 549 EXPECT_EQ(info.decoding_calls_to_neteq, stats.decoding_calls_to_neteq);
546 EXPECT_EQ(info.decoding_normal, stats.decoding_normal); 550 EXPECT_EQ(info.decoding_normal, stats.decoding_normal);
547 EXPECT_EQ(info.decoding_plc, stats.decoding_plc); 551 EXPECT_EQ(info.decoding_plc, stats.decoding_plc);
548 EXPECT_EQ(info.decoding_cng, stats.decoding_cng); 552 EXPECT_EQ(info.decoding_cng, stats.decoding_cng);
549 EXPECT_EQ(info.decoding_plc_cng, stats.decoding_plc_cng); 553 EXPECT_EQ(info.decoding_plc_cng, stats.decoding_plc_cng);
550 EXPECT_EQ(info.decoding_muted_output, stats.decoding_muted_output); 554 EXPECT_EQ(info.decoding_muted_output, stats.decoding_muted_output);
551 EXPECT_EQ(info.capture_start_ntp_time_ms, stats.capture_start_ntp_time_ms); 555 EXPECT_EQ(info.capture_start_ntp_time_ms, stats.capture_start_ntp_time_ms);
552 } 556 }
557 void VerifyVoiceSendRecvCodecs(const cricket::VoiceMediaInfo& info) const {
558 EXPECT_EQ(send_parameters_.codecs.size(), info.send_codecs.size());
559 for (const cricket::AudioCodec& codec : send_parameters_.codecs) {
560 ASSERT_EQ(info.send_codecs.count(codec.id), 1U);
561 EXPECT_EQ(info.send_codecs.find(codec.id)->second,
562 codec.ToCodecParameters());
563 }
564 EXPECT_EQ(recv_parameters_.codecs.size(), info.receive_codecs.size());
565 for (const cricket::AudioCodec& codec : recv_parameters_.codecs) {
566 ASSERT_EQ(info.receive_codecs.count(codec.id), 1U);
567 EXPECT_EQ(info.receive_codecs.find(codec.id)->second,
568 codec.ToCodecParameters());
569 }
570 }
553 571
554 protected: 572 protected:
555 StrictMock<webrtc::test::MockAudioDeviceModule> adm_; 573 StrictMock<webrtc::test::MockAudioDeviceModule> adm_;
556 StrictMock<webrtc::test::MockAudioProcessing> apm_; 574 StrictMock<webrtc::test::MockAudioProcessing> apm_;
557 webrtc::RtcEventLogNullImpl event_log_; 575 webrtc::RtcEventLogNullImpl event_log_;
558 cricket::FakeCall call_; 576 cricket::FakeCall call_;
559 cricket::FakeWebRtcVoiceEngine voe_; 577 cricket::FakeWebRtcVoiceEngine voe_;
560 std::unique_ptr<cricket::WebRtcVoiceEngine> engine_; 578 std::unique_ptr<cricket::WebRtcVoiceEngine> engine_;
561 cricket::VoiceMediaChannel* channel_ = nullptr; 579 cricket::VoiceMediaChannel* channel_ = nullptr;
562 cricket::AudioSendParameters send_parameters_; 580 cricket::AudioSendParameters send_parameters_;
(...skipping 1682 matching lines...) Expand 10 before | Expand all | Expand 10 after
2245 // Check stats for the added streams. 2263 // Check stats for the added streams.
2246 { 2264 {
2247 cricket::VoiceMediaInfo info; 2265 cricket::VoiceMediaInfo info;
2248 EXPECT_EQ(true, channel_->GetStats(&info)); 2266 EXPECT_EQ(true, channel_->GetStats(&info));
2249 2267
2250 // We have added 4 send streams. We should see empty stats for all. 2268 // We have added 4 send streams. We should see empty stats for all.
2251 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size()); 2269 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size());
2252 for (const auto& sender : info.senders) { 2270 for (const auto& sender : info.senders) {
2253 VerifyVoiceSenderInfo(sender, false); 2271 VerifyVoiceSenderInfo(sender, false);
2254 } 2272 }
2273 VerifyVoiceSendRecvCodecs(info);
2255 2274
2256 // We have added one receive stream. We should see empty stats. 2275 // We have added one receive stream. We should see empty stats.
2257 EXPECT_EQ(info.receivers.size(), 1u); 2276 EXPECT_EQ(info.receivers.size(), 1u);
2258 EXPECT_EQ(info.receivers[0].ssrc(), 0); 2277 EXPECT_EQ(info.receivers[0].ssrc(), 0);
2259 } 2278 }
2260 2279
2261 // Remove the kSsrc2 stream. No receiver stats. 2280 // Remove the kSsrc2 stream. No receiver stats.
2262 { 2281 {
2263 cricket::VoiceMediaInfo info; 2282 cricket::VoiceMediaInfo info;
2264 EXPECT_TRUE(channel_->RemoveRecvStream(kSsrc2)); 2283 EXPECT_TRUE(channel_->RemoveRecvStream(kSsrc2));
2265 EXPECT_EQ(true, channel_->GetStats(&info)); 2284 EXPECT_EQ(true, channel_->GetStats(&info));
2266 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size()); 2285 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size());
2267 EXPECT_EQ(0u, info.receivers.size()); 2286 EXPECT_EQ(0u, info.receivers.size());
2268 } 2287 }
2269 2288
2270 // Deliver a new packet - a default receive stream should be created and we 2289 // Deliver a new packet - a default receive stream should be created and we
2271 // should see stats again. 2290 // should see stats again.
2272 { 2291 {
2273 cricket::VoiceMediaInfo info; 2292 cricket::VoiceMediaInfo info;
2274 DeliverPacket(kPcmuFrame, sizeof(kPcmuFrame)); 2293 DeliverPacket(kPcmuFrame, sizeof(kPcmuFrame));
2275 SetAudioReceiveStreamStats(); 2294 SetAudioReceiveStreamStats();
2276 EXPECT_EQ(true, channel_->GetStats(&info)); 2295 EXPECT_EQ(true, channel_->GetStats(&info));
2277 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size()); 2296 EXPECT_EQ(static_cast<size_t>(arraysize(kSsrcs4)), info.senders.size());
2278 EXPECT_EQ(1u, info.receivers.size()); 2297 EXPECT_EQ(1u, info.receivers.size());
2279 VerifyVoiceReceiverInfo(info.receivers[0]); 2298 VerifyVoiceReceiverInfo(info.receivers[0]);
2299 VerifyVoiceSendRecvCodecs(info);
2280 } 2300 }
2281 } 2301 }
2282 2302
2283 // Test that we can add and remove receive streams, and do proper send/playout. 2303 // Test that we can add and remove receive streams, and do proper send/playout.
2284 // We can receive on multiple streams while sending one stream. 2304 // We can receive on multiple streams while sending one stream.
2285 TEST_F(WebRtcVoiceEngineTestFake, PlayoutWithMultipleStreams) { 2305 TEST_F(WebRtcVoiceEngineTestFake, PlayoutWithMultipleStreams) {
2286 EXPECT_TRUE(SetupSendStream()); 2306 EXPECT_TRUE(SetupSendStream());
2287 2307
2288 // Start playout without a receive stream. 2308 // Start playout without a receive stream.
2289 SetSendParameters(send_parameters_); 2309 SetSendParameters(send_parameters_);
(...skipping 163 matching lines...) Expand 10 before | Expand all | Expand 10 after
2453 EXPECT_EQ(info.receivers.size(), 1u); 2473 EXPECT_EQ(info.receivers.size(), 1u);
2454 EXPECT_EQ(info.receivers[0].ssrc(), 0); 2474 EXPECT_EQ(info.receivers[0].ssrc(), 0);
2455 } 2475 }
2456 2476
2457 // Start sending - this affects some reported stats. 2477 // Start sending - this affects some reported stats.
2458 { 2478 {
2459 cricket::VoiceMediaInfo info; 2479 cricket::VoiceMediaInfo info;
2460 SetSend(true); 2480 SetSend(true);
2461 EXPECT_EQ(true, channel_->GetStats(&info)); 2481 EXPECT_EQ(true, channel_->GetStats(&info));
2462 VerifyVoiceSenderInfo(info.senders[0], true); 2482 VerifyVoiceSenderInfo(info.senders[0], true);
2483 VerifyVoiceSendRecvCodecs(info);
2463 } 2484 }
2464 2485
2465 // Remove the kSsrc2 stream. No receiver stats. 2486 // Remove the kSsrc2 stream. No receiver stats.
2466 { 2487 {
2467 cricket::VoiceMediaInfo info; 2488 cricket::VoiceMediaInfo info;
2468 EXPECT_TRUE(channel_->RemoveRecvStream(kSsrc2)); 2489 EXPECT_TRUE(channel_->RemoveRecvStream(kSsrc2));
2469 EXPECT_EQ(true, channel_->GetStats(&info)); 2490 EXPECT_EQ(true, channel_->GetStats(&info));
2470 EXPECT_EQ(1u, info.senders.size()); 2491 EXPECT_EQ(1u, info.senders.size());
2471 EXPECT_EQ(0u, info.receivers.size()); 2492 EXPECT_EQ(0u, info.receivers.size());
2472 } 2493 }
2473 2494
2474 // Deliver a new packet - a default receive stream should be created and we 2495 // Deliver a new packet - a default receive stream should be created and we
2475 // should see stats again. 2496 // should see stats again.
2476 { 2497 {
2477 cricket::VoiceMediaInfo info; 2498 cricket::VoiceMediaInfo info;
2478 DeliverPacket(kPcmuFrame, sizeof(kPcmuFrame)); 2499 DeliverPacket(kPcmuFrame, sizeof(kPcmuFrame));
2479 SetAudioReceiveStreamStats(); 2500 SetAudioReceiveStreamStats();
2480 EXPECT_EQ(true, channel_->GetStats(&info)); 2501 EXPECT_EQ(true, channel_->GetStats(&info));
2481 EXPECT_EQ(1u, info.senders.size()); 2502 EXPECT_EQ(1u, info.senders.size());
2482 EXPECT_EQ(1u, info.receivers.size()); 2503 EXPECT_EQ(1u, info.receivers.size());
2483 VerifyVoiceReceiverInfo(info.receivers[0]); 2504 VerifyVoiceReceiverInfo(info.receivers[0]);
2505 VerifyVoiceSendRecvCodecs(info);
2484 } 2506 }
2485 } 2507 }
2486 2508
2487 // Test that we can set the outgoing SSRC properly with multiple streams. 2509 // Test that we can set the outgoing SSRC properly with multiple streams.
2488 // SSRC is set in SetupSendStream() by calling AddSendStream. 2510 // SSRC is set in SetupSendStream() by calling AddSendStream.
2489 TEST_F(WebRtcVoiceEngineTestFake, SetSendSsrcWithMultipleStreams) { 2511 TEST_F(WebRtcVoiceEngineTestFake, SetSendSsrcWithMultipleStreams) {
2490 EXPECT_TRUE(SetupSendStream()); 2512 EXPECT_TRUE(SetupSendStream());
2491 EXPECT_TRUE(call_.GetAudioSendStream(kSsrc1)); 2513 EXPECT_TRUE(call_.GetAudioSendStream(kSsrc1));
2492 EXPECT_TRUE(AddRecvStream(kSsrc2)); 2514 EXPECT_TRUE(AddRecvStream(kSsrc2));
2493 EXPECT_EQ(kSsrc1, GetRecvStreamConfig(kSsrc2).rtp.local_ssrc); 2515 EXPECT_EQ(kSsrc1, GetRecvStreamConfig(kSsrc2).rtp.local_ssrc);
(...skipping 1003 matching lines...) Expand 10 before | Expand all | Expand 10 after
3497 nullptr, webrtc::CreateBuiltinAudioDecoderFactory()); 3519 nullptr, webrtc::CreateBuiltinAudioDecoderFactory());
3498 webrtc::RtcEventLogNullImpl event_log; 3520 webrtc::RtcEventLogNullImpl event_log;
3499 std::unique_ptr<webrtc::Call> call( 3521 std::unique_ptr<webrtc::Call> call(
3500 webrtc::Call::Create(webrtc::Call::Config(&event_log))); 3522 webrtc::Call::Create(webrtc::Call::Config(&event_log)));
3501 cricket::WebRtcVoiceMediaChannel channel(&engine, cricket::MediaConfig(), 3523 cricket::WebRtcVoiceMediaChannel channel(&engine, cricket::MediaConfig(),
3502 cricket::AudioOptions(), call.get()); 3524 cricket::AudioOptions(), call.get());
3503 cricket::AudioRecvParameters parameters; 3525 cricket::AudioRecvParameters parameters;
3504 parameters.codecs = engine.recv_codecs(); 3526 parameters.codecs = engine.recv_codecs();
3505 EXPECT_TRUE(channel.SetRecvParameters(parameters)); 3527 EXPECT_TRUE(channel.SetRecvParameters(parameters));
3506 } 3528 }
OLDNEW
« no previous file with comments | « webrtc/media/engine/webrtcvoiceengine.cc ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698