Am 20.12.2021 um 15:03 schrieb Peter Kronenberg:
Thanks. What I meant about the resolution is that the image created is the
same size as the 8.5 x 11 page. But what is the default DPI of the resulting
image? Is it 72DPI? You say for thumbnails, one should use 72dpi or above.
What is the significance of making it greater? Does that make the resultaint
image greater? When you say to resize it, do you mean with some PDFBox method
call, or externally from PDFBox?
If you render with scale 1, then you get 72dpi. At that dpi, the result
image should have 1 pixel per 1/72 dpi.
72dpi or above so that you have more "material" that you can scale to
the target size, so that the target image will look better. You can test
this for yourself when you have created code that scales to the target
size. (PDFs can have different sizes and orientations, so you'll have to
write something)
Resize with java imaging / java 2D methods.
Tilman
On 2021/12/16 19:13:06 Tilman Hausherr wrote:
Am 16.12.2021 um 20:07 schrieb Peter Kronenberg:
I'm using PdfRenderer.renderImageToDPI() and I'm trying to understand
exactly how the DPI is computed. From looking at the code, it seems
that 72 DPI is the default, meaning that it will have the same
resolution as the original document. Is this correct?
72dpi is like scale 1 with the methods that don't have "dpi" in it.
There is no such thing as "resolution as the original document". The
document could be pure vector graphics. There's only the target.
For thumbnails, a good strategy is to use 72dpi or above, then resize
the result image so it fits into target width / height.
Tilman
I'm my application, I want to create a thumbnail image, but lower the
resolution so that the text is not really readable (even if you zoom
in), but one can still see the structure of the page. So I'm just
trying to understand the terminology
*Peter Kronenberg****| **Senior AI Analytic ENGINEER *
*C: 703.887.5623*
Torch AI <http://www.torch.ai/>
4303 W. 119th St., Leawood, KS 66209
WWW.TORCH.AI <http://www.torch.ai/>
---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@pdfbox.apache.org
For additional commands, e-mail: users-h...@pdfbox.apache.org