Montage Auto Fit/Auto Rotate to fit as many as possible to an A4 page.

Questions and postings pertaining to the development of ImageMagick, feature enhancements, and ImageMagick internals. ImageMagick source code and algorithms are discussed here. Usage questions which are too arcane for the normal user list should also be posted here.
Locked
fraps1986
Posts: 1
Joined: 2020-03-10T05:43:55-07:00
Authentication code: 1152

Montage Auto Fit/Auto Rotate to fit as many as possible to an A4 page.

Post by fraps1986 »

Hi, I was trying to create an A4 size page which has n number of tiled images on it. For example if the source image was A5 I would need it to place 2 of these images. A6, 4 or A7, 8 and so on. I have attempted to and succeeded doing this by using the tile property.

"c:\Program Files\ImageMagick-7.0.7-Q16\montage "E:\Tickets\output.png" -geometry 595x842+1+1 -duplicate 7 -tile 4x2 -density 300 -page A4 "E:\Tickets\final.jpg"

My problem is

A) I was wondering if there was a dynamic way of doing this rather than having to specify the different tiling per example.
B) If I have 4 A7 images and 1 A5 how would I go about fitting these all on the same A4 paper. Especially if an image needed to be rotated to fit?

Locked