Created
July 28, 2019 12:47
-
-
Save ueokande/11ca9442a52de4cdeb89d6de21445be6 to your computer and use it in GitHub Desktop.
Create screenshot GIF
This file contains hidden or 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
# Get window info | |
xwininfo | |
# Save screenshot animation as a PNG format into outputs | |
ffmpeg -video_size $widthx$height -framerate 24 -f x11grab -i :0.0+$x,$y outputs/%04d.png | |
# Generate GIF from PNG images | |
ffmpeg -y -i outputs/%04d.png -ss 2.3 -t 15 -filter_complex "[0:v]setpts=0.7*PTS,split [a][b];[a] palettegen [p];[b][p] paletteuse" screenshot.gif |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment