You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@pdfbox.apache.org by "John Hewson (JIRA)" <ji...@apache.org> on 2015/11/12 19:59:11 UTC

[jira] [Comment Edited] (PDFBOX-3101) Chinese character displayed with bad quality

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

John Hewson edited comment on PDFBOX-3101 at 11/12/15 6:58 PM:
---------------------------------------------------------------

These characters are embedded as bitmaps which is why the quality is low, even in Acrobat. However, the quality is particularly poor in PDFBox. That's because Java2D doesn't scale images particularly well and these images are being scaled down by a factor of eight.

The good news is that you can work around this by rendering the page image at a higher scale than you need, e.g. 4x and then scaling-down the resulting image by 4x using a [high-quality image scaling algorithm|https://github.com/mortennobel/java-image-scaling].


was (Author: jahewson):
These characters are embedded as bitmaps which is why the quality is low, even in Acrobat. However, the quality is particularly poor in PDFBox. That's because Java2D doesn't scale images particularly well and theses images are being scaled down by a factor of eight.

The good news is that you can work around this by rendering the page image at a higher scale than you need, e.g. 4x and then scaling-down the resulting image by 4x using a [high-quality image scaling algorithm|https://github.com/mortennobel/java-image-scaling].

> Chinese character displayed with bad quality
> --------------------------------------------
>
>                 Key: PDFBOX-3101
>                 URL: https://issues.apache.org/jira/browse/PDFBOX-3101
>             Project: PDFBox
>          Issue Type: Bug
>          Components: Rendering
>    Affects Versions: 2.0.0
>         Environment: ubuntu 12.04 NetBeans IDE 8.0.2
>            Reporter: ZHOU Jing
>         Attachments: 1.png, ConvertPDFToImages.java, ZH_PDF.pdf
>
>
> When I use PDFRender to render the following PDF file to PNG image, the Chinese Character is displayed in poor quality with dashed lines.



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

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@pdfbox.apache.org
For additional commands, e-mail: dev-help@pdfbox.apache.org