Created
January 13, 2020 15:10
-
-
Save LaineZ/158d6621b098164c4bfa2f3bc000c753 to your computer and use it in GitHub Desktop.
BAT GIF Encoder (FFmpeg)
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
:: A small batch adaptation of this script http://blog.pkh.me/p/21-high-quality-gif-with-ffmpeg.html | |
:: USAGE | |
:: gifenc.bat [inputfile] [outputfile] [xsize] [ysize] | |
SET palette="palette.png" | |
SET filters="fps=15,scale=%3:%4:flags=lanczos" | |
ffmpeg -i %1 -vf "%filters%,palettegen" -y %palette% | |
ffmpeg -i %1 -i %palette% -lavfi "%filters% [x]; [x][1:v] paletteuse" -y %2 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment