OLD | NEW |
1 /* | 1 /* |
2 * Copyright (c) 2013 The WebRTC project authors. All Rights Reserved. | 2 * Copyright (c) 2013 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 #include <algorithm> | 10 #include <algorithm> |
(...skipping 387 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
398 H264Decoder::Create()); | 398 H264Decoder::Create()); |
399 RunBaseTest(&test); | 399 RunBaseTest(&test); |
400 } | 400 } |
401 | 401 |
402 TEST_P(EndToEndTest, SendsAndReceivesH264VideoRotation90) { | 402 TEST_P(EndToEndTest, SendsAndReceivesH264VideoRotation90) { |
403 CodecObserver test(5, kVideoRotation_90, "H264", | 403 CodecObserver test(5, kVideoRotation_90, "H264", |
404 H264Encoder::Create(cricket::VideoCodec("H264")), | 404 H264Encoder::Create(cricket::VideoCodec("H264")), |
405 H264Decoder::Create()); | 405 H264Decoder::Create()); |
406 RunBaseTest(&test); | 406 RunBaseTest(&test); |
407 } | 407 } |
| 408 |
| 409 TEST_P(EndToEndTest, SendsAndReceivesH264PacketizationMode0) { |
| 410 cricket::VideoCodec codec = cricket::VideoCodec("H264"); |
| 411 codec.SetParam(cricket::kH264FmtpPacketizationMode, "0"); |
| 412 CodecObserver test(500, kVideoRotation_0, "H264", H264Encoder::Create(codec), |
| 413 H264Decoder::Create()); |
| 414 RunBaseTest(&test); |
| 415 } |
| 416 |
| 417 TEST_P(EndToEndTest, SendsAndReceivesH264PacketizationMode1) { |
| 418 cricket::VideoCodec codec = cricket::VideoCodec("H264"); |
| 419 codec.SetParam(cricket::kH264FmtpPacketizationMode, "1"); |
| 420 CodecObserver test(500, kVideoRotation_0, "H264", H264Encoder::Create(codec), |
| 421 H264Decoder::Create()); |
| 422 RunBaseTest(&test); |
| 423 } |
| 424 |
408 #endif // defined(WEBRTC_USE_H264) | 425 #endif // defined(WEBRTC_USE_H264) |
409 | 426 |
410 TEST_P(EndToEndTest, ReceiverUsesLocalSsrc) { | 427 TEST_P(EndToEndTest, ReceiverUsesLocalSsrc) { |
411 class SyncRtcpObserver : public test::EndToEndTest { | 428 class SyncRtcpObserver : public test::EndToEndTest { |
412 public: | 429 public: |
413 SyncRtcpObserver() : EndToEndTest(kDefaultTimeoutMs) {} | 430 SyncRtcpObserver() : EndToEndTest(kDefaultTimeoutMs) {} |
414 | 431 |
415 Action OnReceiveRtcp(const uint8_t* packet, size_t length) override { | 432 Action OnReceiveRtcp(const uint8_t* packet, size_t length) override { |
416 test::RtcpPacketParser parser; | 433 test::RtcpPacketParser parser; |
417 EXPECT_TRUE(parser.Parse(packet, length)); | 434 EXPECT_TRUE(parser.Parse(packet, length)); |
(...skipping 3623 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
4041 std::unique_ptr<VideoEncoder> encoder_; | 4058 std::unique_ptr<VideoEncoder> encoder_; |
4042 std::unique_ptr<VideoDecoder> decoder_; | 4059 std::unique_ptr<VideoDecoder> decoder_; |
4043 rtc::CriticalSection crit_; | 4060 rtc::CriticalSection crit_; |
4044 int recorded_frames_ GUARDED_BY(crit_); | 4061 int recorded_frames_ GUARDED_BY(crit_); |
4045 } test(this); | 4062 } test(this); |
4046 | 4063 |
4047 RunBaseTest(&test); | 4064 RunBaseTest(&test); |
4048 } | 4065 } |
4049 | 4066 |
4050 } // namespace webrtc | 4067 } // namespace webrtc |
OLD | NEW |