AnnexB - ltqusst/video_notes GitHub Wiki

How to extract AnnexB file from any container?

Use following Bit Stream Filters(-bsf) of ffmpeg while copying the bit-stream:

   ffmpeg -i somefile.xxx {-vcodec|-c:v} copy -bsf {h264|hevc}_mp4toannexb -an -f rawvideo out.xxx

   -an (output)
       Disable audio recording.
   -f fmt (input/output)
       Force input or output file format. The format is normally auto detected for input files and 
       guessed from the file extension for output files, so this option is not needed in most cases.
       but in our cases, the output extension is informal, so we need specify rawvideo format.