[Question] How to predict the page size of the resulting document (in PDF units)? #97

Closed
opened 2021-05-04 10:44:35 +00:00 by mara0004 · 5 comments
Contributor

Is there a way to reliably predict the size of the resulting PDF page based on the image size?

Is there a way to reliably predict the size of the resulting PDF page based on the image size?
Owner

By default (if --border or --pagesize and similar options are not used) the size of the page is equal to the size of the image, using the dpi value embedded in many image formats. If an image does not contain a dpi value in its metadata, then the default dpi value is 96. This is also all explained in the --help output. Can you point out where the current documentation is missing or unclear with respect to your question?

By default (if `--border` or `--pagesize` and similar options are not used) the size of the page is equal to the size of the image, using the dpi value embedded in many image formats. If an image does not contain a dpi value in its metadata, then the default dpi value is 96. This is also all explained in the `--help` output. Can you point out where the current documentation is missing or unclear with respect to your question?
Author
Contributor

Thanks for the explanation. Actually the documentation is pretty clear, I simply overlooked the relevant passage. Sorry.

Thanks for the explanation. Actually the documentation is pretty clear, I simply overlooked the relevant passage. Sorry.
mara0004 changed title from [Question] How to predict the page size of the resulting PDF? to [Question] How to predict the page size of the resulting document (in PDF units)? 2021-05-04 14:17:22 +00:00

@josch How was 96 chosen?

@josch How was 96 chosen?
Owner

Good question. I'm not entirely sure anymore! There are a couple of software packages that have 96 as the default dpi. Do you have a good argument for a different value?

Good question. I'm not entirely sure anymore! There are a couple of software packages that have 96 as the default dpi. Do you have a good argument for a different value?

I could be a wisecrack and recommend 42. 69, or 98.6. But instead I have a more radical, and I think, reasoned idea for your consideration...

#189

I could be a wisecrack and recommend 42. 69, or 98.6. But instead I have a more radical, and I think, reasoned idea for your consideration... https://gitlab.mister-muffin.de/josch/img2pdf/issues/189
Sign in to join this conversation.
No milestone
No project
No assignees
3 participants
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#97
No description provided.