Page 1 of 1

Posted: 2006-08-10T14:55:51-07:00
by ridera
I solved this problem by simply measuring the X and Y ratio and resizing as required.

Posted: 2006-08-10T23:48:11-07:00
by anthony
If you know the image has a 4:3 or a 3:4 aspect ratio... then just resize the image to the larger size and the other will be automatically handled.

EG: -resize 800x800
will do what you asked. It will fit the image into that sized box and adjust the dimensions to preserve the aspect ratio.

If you have no control of your images aspect ratio, then you will need to define exactly what you want done EG if you are given a 1024x20 image (a section seperator 'line' for a web page, what do you want as a result.

Basically the solution depends on how much control you have on the input images.
For more see IM Examples Resize
http://www.cit.gu.edu.au/~anthony/graph ... k6/resize/
and more specific (and smaller scale) examples
http://www.cit.gu.edu.au/~anthony/graph ... humbnails/

Posted: 2006-08-14T00:42:30-07:00
by anthony
You are most welcome.

Often the default action of IM is just what you need, if you just allow it to do its job ;-)