php - ImageMagick Crop Square from Circle?
I have a 424x318 image that I "draw" a circle into and leave the rest transparent. I want to then take that circle and crop it out. How can I do this?
My function (the bash variables are just the normal stuff, $SCALEFILE is the file, $NEWFILE is what it saves it as and $SIZE is just the normal size string x0,y0 x1,y1)
convert -size 416x318 xc:none -fill $SCALEFILE -draw "circle $SIZE" $NEWFILE
ps. my circle dimensions change.