A script that provides an easy method for straightening pictures and then, optionally cropping them to remove the resulting transparent areas.
The centre of rotation can be specified as can the type of cropping required.
The cropping can be performed by the GIMP rotate function but this can have unpredictable results. The Post Rotate Crop script provides more options and seems more reliable (let me know should you find a problem with it)
This version of Straighten and Crop uses the revised interface to the Post Rotate Crop script, including the option to select the aspect ratio of the cropped area.
The attached zip file includes the script and a text file of notes on its use.
| Attachment | Size |
|---|---|
| StraightenAndCrop.zip | 5.67 KB |
Comments
Updated version
I have updated the attachment. The script closes its undo group before calling Post Rotate Crop so that GIMP doesn't report an inconsistency if Post Rotate Crop has to report an error. Also limited the specified aspect ratio height and width to minimum values of 1.
needs postrotatecrop.scm
Sorry if I'm just being a noob, but it wasn't obvious to me that this script depends upon another script being present. I got a "can't find postrotatecrop.scm" error the first time I ran this script.
It can be found at: http://registry.gimp.org/node/18820
Other than that, an easy to use and useful script. Thanks!