Add dofile for Mineclonia menu icon PNG

This commit is contained in:
Nils Dagsson Moskopp 2021-08-23 18:06:32 +02:00
parent cef3669ee2
commit c83278d3ff
No known key found for this signature in database
GPG Key ID: A3BC671C35191080
1 changed files with 15 additions and 0 deletions

15
menu/icon.png.do Normal file
View File

@ -0,0 +1,15 @@
#!/bin/sh
set -eu
SVG_FILE=${2%.png}.svg
# How crisp a Minetest menu icon appears is influenced by image height
# and width. Low resolutions lead to blurry edges, as Minetest scales
# menu icons up. High resolutions lead to jagged edges, as Minetest
# scales menu icons down. Height & width of 72 pixes seem to work.
>&2 inkscape \
--file="${SVG_FILE}" \
--export-png="${3}" \
--export-area-page \
--export-height 72 \
--export-width 72 \