First: (pretty simple, just applies the overlay to image and saves as result)
Code: Select all
composite -gravity center overlay.png image.png result.png
Code: Select all
convert result.png -resize 128x128! \
-format 'roundrectangle 1,1 %[fx:w+0],%[fx:h+0] 10,10' \
-write info:tmp.mvg \
-matte -bordercolor none -border 1 \
\( +clone -alpha transparent -background none \
-fill white -stroke none -strokewidth 0 -draw @tmp.mvg \) \
-compose DstIn -composite \
\( +clone -alpha transparent -background none \) \
-compose Over -composite final.png
rm -f tmp.mvg
Code: Select all
composite -gravity center overlay.png image.png miff:- |\
convert -resize 128x128! \
-format 'roundrectangle 1,1 %[fx:w+0],%[fx:h+0] 10,10' \
-write info:tmp.mvg \
-matte -bordercolor none -border 1 \
\( +clone -alpha transparent -background none \
-fill white -stroke none -strokewidth 0 -draw @tmp.mvg \) \
-compose DstIn -composite \
\( +clone -alpha transparent -background none \) \
-compose Over -composite final.png
[b]Error: [/b]convert: image sequence is required `+clone' @ convert.c/ConvertImageCommand/865.
Thanks!