Generally, there is a unit separator nal at the beginning, and the data packet between the two unit delimiters is an image. 00 00 01 09, which is the unit separator. However, the Protocol does not say that the nal stream must be so organized, and there may be other forms of organization. My h264 files are organized in this way.
The byte stream of h264 does not have the frame concept. Please carefully study the protocol for specific reasons.
It depends on how you understand it. Compared with MPEG2 and MPEG4, the frame format in the H.264 byte stream has changed. Taking video frames as an example, MPEG2 and MPEG4 byte streams extract key frame parameters during transmission and encapsulate them into the first transmission packet, such as Ts or RTP packets, the data in the packet load is still a complete image frame. That is to say, even if you do not use the packet load parameter information set in the packet header, you can perform correct decoding based on the frame data in the packet load.
H. the 264 bitstream itself processes the image data, decomposes a complete image frame, extracts the frame information such as the sequence parameter set and image parameter set, and puts them in their corresponding nal, the image data is encapsulated in the encoding band. In this way, in the nal stream, the image cannot be parsed only based on the nal unit of the encoding strip, and must be combined with the nal of the sequence parameter set and image parameter set to solve the problem. That is to say, a frame of data encoded by MPEG2 and MPEG4 is divided into multiple NAL units in H.264, And the abstraction of H.264 encoding is higher. But h. the 264 code stream is still in the unit of one frame of data during the organization. It does not combine multiple frames of data, but is shown in the form, multiple NAL units are required to form a complete data frame.
From http://hi.baidu.com/ccqi0000/blog/item/f6d26249d9c7d517b2de052e.html