Trim canvas to only fit image?
Posted: 2008-04-09T13:02:50-07:00
I have a series of images, each one sits on a 300x300 white background and are centered on the x and y axis.
I need to trim down the white background or "canvas" so that it is cropped tightly around the image ... say 10px padding.
The problem is that all of the images on the backgrounds are different sizes in regard to width and height so I can't pass coordinates to the crop command. Is there a way to auto detect where the image is on the background canvas and then autocrop around the image?
I need to trim down the white background or "canvas" so that it is cropped tightly around the image ... say 10px padding.
The problem is that all of the images on the backgrounds are different sizes in regard to width and height so I can't pass coordinates to the crop command. Is there a way to auto detect where the image is on the background canvas and then autocrop around the image?