Created
May 11, 2021 00:36
-
-
Save EmperorPenguin18/cdcb8d6b633d5a5f7f84ceb84bcf5b9a to your computer and use it in GitHub Desktop.
Display an animated gif in the terminal
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/bin/sh | |
VIDEO="${1:-test.mp4}" | |
GIF="${2:-test.gif}" | |
ffmpeg -ss 61.0 -t 2.5 -i "$VIDEO" -filter_complex "[0:v] fps=12,scale=w=480:h=-1,split [a][b];[a] palettegen=stats_mode=single [p];[b][p] paletteuse=new=1" "$GIF" | |
chafa "$GIF" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
hi