[ 
https://issues.apache.org/jira/browse/PDFBOX-3523?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=15551061#comment-15551061
 ] 

Tilman Hausherr commented on PDFBOX-3523:
-----------------------------------------

IrfanView is a windows application that you can use to view images. If you 
press "i" it will show you an information box that contains the number of 
unique colors.

"xform" is an Affine Transformation; very simplified it contains your 
resolution.

"ctm" is the current transformation matrix and also an Affine Transformation; 
it contains any size changes, rotations, flips, shears that take place in the 
PDF to display images, texts etc.

What is happening that we're made the decision to use high quality 
interpolation, which makes your images bigger, but of higher quality. You can 
see the higher quality in the images I attached yesterdays.

So now there are these possibilities:
- you look at the images and like the higher quality => we're done
- you insist that you want the lower quality, smaller images (like the 
"-with-change" images)
  if so, I could create a version for you, but not for a general release, I 
would do it tonight, tell you where to find it, but I would remove the change 
later. We need something more general, i.e. configurable. If you know how to 
build from source, the file to change is PageDrawer.java, just replace the 
statement that starts with "boolean isScaledUp" with the 4 lines I posted.


> PDFBox renders images 5 times slower and bigger
> -----------------------------------------------
>
>                 Key: PDFBOX-3523
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3523
>             Project: PDFBox
>          Issue Type: Improvement
>    Affects Versions: 2.0.3
>         Environment: Java version 1.8
> Ubuntu Linux&Windows 10
>            Reporter: Vasiliy Sadokhin
>              Labels: performance
>         Attachments: OldPdfUtils.java, 
> PDFBOX-2302-mori-cvpr01.pdf-7-with-change.png, 
> PDFBOX-2302-mori-cvpr01.pdf-7.png, PdfUtils.java, old_test.png, 
> sigice9_172.Adobe.pdf-1-with-change.png, sigice9_172.Adobe.pdf-1.png, 
> test.pdf, test.png
>
>
> We recently migrated PDFBox from 1.8.13 to 2.0.3. We found that it becomes 5 
> times slower to get a PDF page image and the image is 5 times bigger than 
> PDFBox 1.8 did. For example, It took about 200ms and now it takes more than 1 
> second, the result size was less 200Kb and it's 1Mb now. 
> We specified BufferedImage.TYPE_3BYTE_BGR for PDFBox 1.8 and we have no way 
> to do it with 2.x. It might be a reason.



--
This message was sent by Atlassian JIRA
(v6.3.4#6332)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to