Closed epiccurious closed 1 year ago
Found a solution here: https://stackoverflow.com/questions/9155377/set-transparent-background-using-imagemagick-and-commandline-prompt
color=$( convert bitcoin.png -format "%[pixel:p{0,0}]" info:- )
convert bitcoin.png -alpha off -bordercolor $color -border 1 \( +clone -fuzz 3-% -fill none -floodfill +0+0 $color -alpha extract -geometry 200% -blur 0x0.5 -morphology erode square:1 -geometry 50% \) -compose CopyOpacity -composite -shave 1 transparent.png
It's tricky because we can't just make the white transparent.