0

I'm an ios programmer my server gave me h264 data with TCP but the data is not freindly like this

enter image description here

The startcode (00 00 00 01 or 00 00 01) is not at the start of each response data

So how can i get a whole nalu?

Simon West
  • 3,708
  • 1
  • 26
  • 28
  • There are multiple formats for H.264 streams. The one in your image is `Annex B` which uses that sequence of bytes as NALU start codes. Your server might send another format. See [this answer](http://stackoverflow.com/questions/24884827/possible-locations-for-sequence-picture-parameter-sets-for-h-264-stream) for some examples. – aergistal Nov 13 '15 at 09:32
  • Is byte's endianness a possible issue? Also does the server constantly stream data (as in when you get connected, you might begin in the middle of some NALU bytes)? If so then just ignore the **0xF6** and roll with **x00 x00 x01** onwards (assuming that is the NALU start code) – VC.One Nov 18 '15 at 07:56

0 Answers0