How to crop image with transparent border
I'm looking for the easiest/quickest way to crop the image below to remove the transparent border in Photoshop CS5. Source image available here.
I have lots of these so I'm looking for some consistency where I can batch convert several at the same time. Each image is exactly the same size (with transparent border 512x512 pixels) and the remaining image should be the same size for all them so I can resize the image down to 32x32 pixels whilst retaining square proportions.
Steps I've tried so far
Rectangular Marquee Tool to select as much of the red as possible
The problem is that it's a little inconsistent as it either doesn't select properly (see Image1) or it still leaves a small transparent border (see Image2) and so is not always square.
Can anyone advise a better way to do this which I can run as a batch against lots of similar type images?
If you want to automate the process through batch command, then simply apply trim to all the images, and then you can apply canvas re-size command