原因是 mencode 转换为x264 到mkv和MP4时没有带上默认的 global_header, 而 mkv和mp4默认是需要 global_header ,参见
https://wiki.archlinux.org/index.php/MEncoder
Single-pass x264 (very high-quality)
mencoder original_video.avi -oac copy -ovc x264 -x264encopts preset=veryslow:tune=film:crf=15:frameref=15:fast_pskip=0:threads=auto -sub original_video.srt -subfont-text-scale 3 -o output_video.avi
- The following example uses the option -of lavf to mux the output into a Matroska container which is autodetected from the output file extension .mkv
mencoder original_video.avi -oac copy -of lavf -ovc x264 -x264encopts preset=veryslow:tune=film:crf=15:frameref=15:fast_pskip=0:global_header:threads=auto -sub original_video.srt -subfont-text-scale 3 -o output_video.mkv
- global_header writes global video headers to extradata, or in front of keyframes and is typically required for .mp4 and .mkv containers.
解决办法 在 Any Video Converter 的x264 options 里加上:
global_header