Created
October 15, 2017 23:04
-
-
Save Calinou/eaa87ea1bcfba0d488fadbf560d304b6 to your computer and use it in GitHub Desktop.
Render my avatar into PNGs of several sizes
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
@ECHO OFF | |
mkdir "dist\" | |
for /L %%a in (24, 24, 480) do ( | |
convert -scale %%a "src\avatar-foreground.png" "%TMP%\avatar-foreground-%%a.png" | |
"%PROGRAMFILES%\Inkscape\inkscape.exe" "src\avatar-background.svg" --export-width %%a --export-height %%a --export-png "%TMP%\avatar-background-%%a.png" | |
composite "%TMP%\avatar-foreground-%%a.png" "%TMP%\avatar-background-%%a.png" "%TMP%\avatar-%%a.png" | |
oxipng -o6 "%TMP%\avatar-%%a.png" | |
copy "%TMP%\avatar-%%a.png" "dist\avatar-%%a.png" | |
) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment