extend to certain number of pixels #68

Closed
opened 2021-04-25 19:58:36 +00:00 by josch · 0 comments
Owner

By Name on 2020-01-31T08:43:14.224Z

I have several scanned b/w png images with all the same resolution (1200 dpi) but of different size.
Now I would like to extend them all with a white border to a certain number of pixels but the border size would be different for each png. Using "-S" also does not work as this scales each png differently.
How can this be done by img2pdf? Or do you know another alternative?

Thanks!


By josch on 2020-02-01T08:32:05.912Z


Okay, so if I understand correctly, you would like to have all your images scaled by the same factor and then place them on equally sized pages? Did you try setting --imgsize 1200dpi --pagesize XxY where you replace X and Y by a value that allows all your images to fit into that page?


By Name on 2020-02-01T10:17:16.738Z


oops, sorry, I didn't realize that dpi is also a valid unit. Thanks a lot! It works, great!


By josch on 2020-02-02T13:48:59.172Z


If you think that this issue can be closed, please don't leave it open. Thanks!


By josch on 2020-02-25T04:14:19.501Z


Status changed to closed

*By Name on 2020-01-31T08:43:14.224Z* I have several scanned b/w png images with all the same resolution (1200 dpi) but of different size. Now I would like to extend them all with a white border to a certain number of pixels but the border size would be different for each png. Using "-S" also does not work as this scales each png differently. How can this be done by img2pdf? Or do you know another alternative? Thanks! --- *By josch on 2020-02-01T08:32:05.912Z* --- Okay, so if I understand correctly, you would like to have all your images scaled by the same factor and then place them on equally sized pages? Did you try setting --imgsize 1200dpi --pagesize XxY where you replace X and Y by a value that allows all your images to fit into that page? --- *By Name on 2020-02-01T10:17:16.738Z* --- oops, sorry, I didn't realize that dpi is also a valid unit. Thanks a lot! It works, great! --- *By josch on 2020-02-02T13:48:59.172Z* --- If you think that this issue can be closed, please don't leave it open. Thanks! --- *By josch on 2020-02-25T04:14:19.501Z* --- Status changed to closed
josch closed this issue 2021-04-25 19:58:36 +00:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference: josch/img2pdf#68
No description provided.