简体   繁体   中英

Decoding h264 on ios

This is based on the answer you provided for this thread. Can CMSampleBuffer decode H264 frames? Can you give more pointers , how you achieved it ? I am getting a h264 raw stream from socket on my iphone. How to play it ? hope you will give some hints.

Unfortunately Apple doesn't give us direct access to the hardware, and there's no way (as far as I know) to just get the AVAssetReader to take raw h.264 data. Perhaps somebody has figured it out and would be kind enough to shed some light on it for us.

So the other solution would be to write it to an MP4 file on disk, or switch to HLS as your streaming method. You could also switch to a software decoder. That would solve your problem but give you a new problem in that it will eat up a lot of CPU resources if you're doing HD at a high frame rate.

您可以使用Apple Inc.提供的FFMPGE或VideoToolKit框架。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM