| 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 875 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
| 886 } | 886 } |
| 887 | 887 |
| 888 TEST_F(RtpDepacketizerH264Test, TestSeiPacket) { | 888 TEST_F(RtpDepacketizerH264Test, TestSeiPacket) { |
| 889 const uint8_t kPayload[] = { | 889 const uint8_t kPayload[] = { |
| 890 kSei, // F=0, NRI=0, Type=6. | 890 kSei, // F=0, NRI=0, Type=6. |
| 891 0x03, 0x03, 0x03, 0x03 // Payload. | 891 0x03, 0x03, 0x03, 0x03 // Payload. |
| 892 }; | 892 }; |
| 893 RtpDepacketizer::ParsedPayload payload; | 893 RtpDepacketizer::ParsedPayload payload; |
| 894 ASSERT_TRUE(depacketizer_->Parse(&payload, kPayload, sizeof(kPayload))); | 894 ASSERT_TRUE(depacketizer_->Parse(&payload, kPayload, sizeof(kPayload))); |
| 895 const RTPVideoHeaderH264& h264 = payload.type.Video.codecHeader.H264; | 895 const RTPVideoHeaderH264& h264 = payload.type.Video.codecHeader.H264; |
| 896 EXPECT_EQ(kVideoFrameDelta, payload.frame_type); |
| 896 EXPECT_EQ(kH264SingleNalu, h264.packetization_type); | 897 EXPECT_EQ(kH264SingleNalu, h264.packetization_type); |
| 897 EXPECT_EQ(kSei, h264.nalu_type); | 898 EXPECT_EQ(kSei, h264.nalu_type); |
| 898 ASSERT_EQ(1u, h264.nalus_length); | 899 ASSERT_EQ(1u, h264.nalus_length); |
| 899 EXPECT_EQ(static_cast<H264::NaluType>(kSei), h264.nalus[0].type); | 900 EXPECT_EQ(static_cast<H264::NaluType>(kSei), h264.nalus[0].type); |
| 900 EXPECT_EQ(-1, h264.nalus[0].sps_id); | 901 EXPECT_EQ(-1, h264.nalus[0].sps_id); |
| 901 EXPECT_EQ(-1, h264.nalus[0].pps_id); | 902 EXPECT_EQ(-1, h264.nalus[0].pps_id); |
| 902 } | 903 } |
| 903 | 904 |
| 904 } // namespace webrtc | 905 } // namespace webrtc |
| OLD | NEW |