Multi-Media Development --- Analysis of haikang code stream

Source: Internet
Author: User

First, thank you.

 

Take some data first. The previous data is the head of haikang, that is, the net_dvr_syshead branch. If this parameter is not described, the bitstream data of the net_dvr_streamdata branch is directly obtained. The start is as follows:

00 00 01 Ba 46 E6 6C A1 14 01 00 03 Fe FF ff00 00 00 01 00 00 01 BC 00 5A E0 ff 00 24 40 0e 48 4B 00 01 0e 30 C2 0d A0 07 FF 41 12 48 4B 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 2C 1B E0 00 10 42 0e 00 00 A0 21 01 60 01 20 12 1f ff 00 3A 99 91 C0 00 0C 43 0a 00 00 Fe 00 7d 03 E8 03 ff bd 00 00 BF 00 00 00 00 00 00 00 00 01 E0 00 1A 8C 80 0a 21 B9 9B 28 45 FF FC 00 00 00 01 67 42 00 14 95 A8 58 25 9000 00 01 E0 00 0e 8C 00 03 ff fc 00 00 00 01 68 ce 3C 8000 00 01 E0 13 fa 8C 00 02 ff fd 00 00 00 01 65 B8 00...

 

 

According to the provisions of the document, the first 14 bytes, that is, 00 00 01 Ba 44 73 26 B8 34 01 00 00 03 Fe, are the PS stream (Program Stream) header, and the last 3 bytes of the 14th bytes, that is, 1111 1110 indicates the length of the Data filled after the header, indicating that there are 6 bytes of data filled, that is, FF 00 00 01, and haikang uses the last byte 01 to indicate that it is 1st frames of data.

 

A package starts with 00 00 01 BC. BC indicates that the package is Program Stream Map. The 5, 6 bytes of the SMS packet, that is, 00 5A indicates that the subsequent data length is 0x00 5A, that is, 90 bytes. The E0 FF has unknown meaning and needs to be analyzed. 00 24 means 36, skipping 36 bytes (00 2C 1B e0.0.) starting from 00 24 ..., among them, 1B indicates the code stream encoding format is H. 264.

 

The package starts with 00 00 01 E0. E0 indicates that this package is a PES package. 00 1A indicates the length of the PES package, which is 26. That is, if 26 bytes are crossed after 00 1A, it will be the next package; 8C is standard data. If this byte is not 8C, the data is incorrect. The last byte is used to determine whether it is PTS or DTS, and 80 indicates PTS; 0a indicates the length of the additional data, that is, the 10 bytes after 0a are the additional data of the PES package, that is, 21 B9 9B 28 45 ff fc, where the first 5 bytes are used to calculate PTS; after the additional data is 264 data, the video data of the PES package is 00 00 00 01 67 42 00 14 95 A8 58 25 90.

 

Some of the above conclusions are tested and demonstrated, and some are purely speculative and for reference only. After comparison with the data provided by the link blog, it can be seen that many of the data in different data streams are common, some have already mined their meanings, and more need to continue mining!

Http://blog.csdn.net/jjy163/article/details/20222919

Multi-Media Development --- Analysis of haikang code stream

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.