Decoding h264 in iOS 8 with video tool box
Need to decode h264 stream and get the pixel buffers I know its possible with video tool box on iOS 8 1.How do I convert the h264 stream to CMSampleBufferRef ? 2.How do I use the video tool box to decode? I assume you get the stream in Annex B format, if it is already in AVCC format (read MP4), then you can you the AssetReader and do not need to do much. For an Annex B stream (this is what ppl. often call raw h264 stream). extract SPS/PPS NAL units and create a parameter set from then. You receive them periodically. They contain information for the decode how a frame is supposed to be decoded.