[FFmpeg-devel] [RFC] Sending H.264 stream to multiple containers
Peng
howtofly at gmail.com
Mon Jul 15 03:00:25 CEST 2013
> My objective is to be able to generate a command like this one
> (requires my pending and unreviewed -tee_bsfs patch):
> ffmpeg -i INPUT -map 0 -flags +global_header -c:v libx264 -c:a libvo_aacenc -tee_bsfs "h264_mp4toannexb:v|aac_adtstoasc:a" -f tee "out.ts|out.mp4"
>
> and avoid the need to remux the generated MP4.
>
> Do you know if this is possible? Do you have specific hints?
Not familiar with the current version of FFmpeg. But I suspect
CODEC_FLAG_GLOBAL_HEADER has anything to do with MP4-compliant H.264
bitstream.
CODEC_FLAG_GLOBAL_HEADER just tells FFmpeg not to repeat SPS+PPS for
every H.264 keyframe, which will be placed in codec->extradata instead.
MP4-compliant H.264 bitstream is produced by replacing NALU startcode by
four-byte NALU length. The h264_mp4toannexb filter does the reverse.
IMO, they are irrelevant.
--
Peng
More information about the ffmpeg-devel
mailing list