Skip to content

Instantly share code, notes, and snippets.

@whoo
Last active October 13, 2025 15:35
Show Gist options
  • Select an option

  • Save whoo/4940bdcbd38479680cbd62d749f6e014 to your computer and use it in GitHub Desktop.

Select an option

Save whoo/4940bdcbd38479680cbd62d749f6e014 to your computer and use it in GitHub Desktop.
# To Apple Video
ffmpeg -i <source> -c:v libx265 -crf 28 -tag:v hvc1 -c:a eac3 -b:a 224k <target.mp4>
#
ffmpeg -i <source> -c:v libx264 -crf 28 -profile:v high -c:a libfdk_aac -b:a 224k <target.mp4>
```
ffmpeg -i $A -i cover.png -c:v libx265 -crf 28 -level 3.1 -tag:v:0 hvc1 -c:a copy -vf subtitles=out.srt,scale=1280:720 -map 0:0 -map 0:1 -map 1:0 -c:v:1 png -disposition:v:1 attached_pic output.mp4
ffmpeg -i $IN -map 0:0 -map 0:2 \
-c:v libx264 -crf 23 -profile:v high -level 3.0 \
-c:a aac -b:a 128k -ac 2 -ar 44100 \
output_strict_quicktime.mp4
ffpb -i {input} -i {cover} -level 3.1 \
-c:v copy -metadata show={title} \
-metadata season_number={season} \
-metadata episode_sort={episode} \
-c:a aac -map 0:0 -map 0:1 -map 1:0
-c:v:1 png -disposition:v:1 attached_pic \
{output.mp4}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment