H264 Video Streaming over RTMP on iOS
问题 With a bit of digging, I have found a library that extracts NAL units from .mp4 file while it is being written. I'm attempting to packetize this information to flv over RTMP using libavformat and libavcodec . I setup a video stream using: -(void)setupVideoStream { int ret = 0; videoCodec = avcodec_find_decoder(STREAM_VIDEO_CODEC); if (videoCodec == nil) { NSLog(@"Could not find encoder %i", STREAM_VIDEO_CODEC); return; } videoStream = avformat_new_stream(oc, videoCodec); videoCodecContext =