0
votes

I need to process some pictures with imagemagick. Those pictures have different proportions and sizes. My goal is to 'zoom' every picture so at the end i'll have a whole DIN-A4 printable surface. Which could be the best approach ? I'm thinking of doing something like this:


fitting image to din a-4

A : I would expand original picture to fit 'DIN A4' height.

B : I would expand A picture to fit 'DIN A-4' width.

C : Final picture has the same aspect ratio and was 'zoomed'

A real example. Pay attention how the butterfly's image is bigger ( zoomed ) in the second one. ( using 'Canon Image Garden software' , print > option without borders' ):

LEFT IMAGE Original file. CENTER IMAGE: how it would look printed covering whole a DIN A4 sheet. RIGHT IMAGE: This is how we'll see the original image printed

enter image description here


I have no idea how could i do this using imagemagick. Any suggestions ?

1

1 Answers

1
votes

To resize an image to A4 size (595 x 842) in ImageMagick, use

convert image -resize 595x842 -background white -gravity center -extent 595x843 result