How to batch resize to a specific aspect ratio by adding white borders
Posted: 2017-01-02T17:25:03-07:00
Hello,
I have a bunch of (scan) jpegs, which have different pixel resolutions and display ratios.
for instance 730x1080, 764x1080, 2059x2912
I which to convert all of them to A4 format, aka 210x297 in whatever sufficient dpi.
It means that some jpeg, do need some white borders on their width, or on their top&bottom borders, in order to output in A4 format.
Border(http://www.imagemagick.org/Usage/crop/#border) could do it if I indivually count for every scan, but here in a batch process I do not know which input ratio I have for each image.
Additionnaly, I wish to resize the longest side to a specific pixel size, say 1200, so that all output have same dpi.
How can I do that?
Thanks
I have a bunch of (scan) jpegs, which have different pixel resolutions and display ratios.
for instance 730x1080, 764x1080, 2059x2912
I which to convert all of them to A4 format, aka 210x297 in whatever sufficient dpi.
It means that some jpeg, do need some white borders on their width, or on their top&bottom borders, in order to output in A4 format.
Border(http://www.imagemagick.org/Usage/crop/#border) could do it if I indivually count for every scan, but here in a batch process I do not know which input ratio I have for each image.
Additionnaly, I wish to resize the longest side to a specific pixel size, say 1200, so that all output have same dpi.
How can I do that?
Thanks