[poppler] Result image stretched slightly

Chris Kovey chrisancode at outlook.com
Mon Nov 13 12:06:06 UTC 2017


Hello, we've hit an odd issue with a PDF being slightly stretched when converting.  For reference here is the PDF and resulting output from commands below https://www.dropbox.com/sh/iandpzudjqw44h1/AADKv56viK8I6YOIjnPkzZWZa?dl=0



If you load the photoshop file in one browser tab and zoom to 100%, then load any of the other test PNGs in another tab and flip back and forth between photoshop and the test you will see elements on the PDF shift and some of the clarity get lost.



For example: compare photoshop-export.png with test1-1.png (our standard way of exporting PDFs).  When you flip back and forth between the 2 images you will notice the blue sky square shifting (among other things), the woman's forehead gets blurred out a bit, not as many freckles, and the fonts losing some clarity.  The "o" in "This season" gets a flat top.



Any idea of what could be causing this or how I could fix it?  Below are the commands I used to test things with



First, I exported the PDF from photoshop as my reference using a 1300 width


[chris at ubuntu resizing] $ identify photoshop-export.png
photoshop-export.png PNG 1300x1826 1300x1826+0+0 8-bit sRGB 1.876MB 0.000u 0:00.000

Our normal routine for exporting images
[chris at ubuntu resizing] $ pdftoppm -png -scale-to-x 1300 -scale-to-y -1 example.pdf test1
[chris at ubuntu resizing] $ identify test1-1.png
test1-1.png PNG 1300x1828 1300x1828+0+0 8-bit sRGB 1.397MB 0.000u 0:00.000

Alternate method
[chris at ubuntu resizing] $ pdftoppm -png -scale-to 1826 example.pdf test2
[chris at ubuntu resizing] $ identify test2-1.png
test2-1.png PNG 1300x1826 1300x1826+0+0 8-bit sRGB 1.393MB 0.000u 0:00.000

Just kinda playing to see
[chris at ubuntu resizing] $ pdftoppm -png -scale-to 1828 example.pdf test3
[chris at ubuntu resizing] $ identify test3-1.png
test3-1.png PNG 1301x1828 1301x1828+0+0 8-bit sRGB 1.397MB 0.000u 0:00.000

Comparing with pdfimages
[chris at ubuntu resizing] $ pdfimages -png example.pdf test4
[chris at ubuntu resizing] $ convert test4-000.png -geometry 1300x test4-sized.png
[chris at ubuntu resizing] $ identify test4-sized.png
test4-sized.png PNG 1300x1827 1300x1827+0+0 8-bit sRGB 1.516MB 0.000u 0:00.000



-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/poppler/attachments/20171113/74b95b44/attachment.html>


More information about the poppler mailing list