Return-Path: Delivered-To: apmail-incubator-pdfbox-dev-archive@minotaur.apache.org Received: (qmail 45207 invoked from network); 8 Jul 2009 06:14:27 -0000 Received: from hermes.apache.org (HELO mail.apache.org) (140.211.11.3) by minotaur.apache.org with SMTP; 8 Jul 2009 06:14:27 -0000 Received: (qmail 36668 invoked by uid 500); 8 Jul 2009 06:14:37 -0000 Delivered-To: apmail-incubator-pdfbox-dev-archive@incubator.apache.org Received: (qmail 36637 invoked by uid 500); 8 Jul 2009 06:14:37 -0000 Mailing-List: contact pdfbox-dev-help@incubator.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: pdfbox-dev@incubator.apache.org Delivered-To: mailing list pdfbox-dev@incubator.apache.org Received: (qmail 36627 invoked by uid 99); 8 Jul 2009 06:14:37 -0000 Received: from athena.apache.org (HELO athena.apache.org) (140.211.11.136) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jul 2009 06:14:37 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=10.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.140] (HELO brutus.apache.org) (140.211.11.140) by apache.org (qpsmtpd/0.29) with ESMTP; Wed, 08 Jul 2009 06:14:35 +0000 Received: from brutus (localhost [127.0.0.1]) by brutus.apache.org (Postfix) with ESMTP id C8DD7234C004 for ; Tue, 7 Jul 2009 23:14:14 -0700 (PDT) Message-ID: <2027119795.1247033654807.JavaMail.jira@brutus> Date: Tue, 7 Jul 2009 23:14:14 -0700 (PDT) From: =?utf-8?Q?Andreas_Lehmk=C3=BChler_=28JIRA=29?= To: pdfbox-dev@incubator.apache.org Subject: [jira] Resolved: (PDFBOX-460) [PATCH] Improvements for bitmap production (resolution and color depth) In-Reply-To: <2030379930.1241257410539.JavaMail.jira@brutus> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 X-Virus-Checked: Checked by ClamAV on apache.org [ https://issues.apache.org/jira/browse/PDFBOX-460?page=3Dcom.atlassia= n.jira.plugin.system.issuetabpanels:all-tabpanel ] Andreas Lehmk=C3=BChler resolved PDFBOX-460. --------------------------------------- Resolution: Fixed I've commited Jeremias patch with version 792043 and recreated the referenc= e bitmaps with version 792045. Thanks Jeremias for the improvement=20 > [PATCH] Improvements for bitmap production (resolution and color depth) > ----------------------------------------------------------------------- > > Key: PDFBOX-460 > URL: https://issues.apache.org/jira/browse/PDFBOX-460 > Project: PDFBox > Issue Type: Improvement > Components: Utilities > Affects Versions: 0.8.0-incubator > Reporter: Jeremias Maerki > Priority: Minor > Fix For: 0.8.0-incubator > > Attachments: bitmap-production-improvements.diff > > > The attached patch improves the PDFToImage utility to support a resolutio= n and color depth setting. > -resolution 300dpi creates a 300 dpi bitmap > -color rgba creates an RGB 24bit image with an 8bit alpha channel > -color rgb creates an RGB 24bit image > -color gray creates an 8bit gray image > -color indexed creates an 8bit color image with 256 indexed colors (that = was what was produced before the change) > -color bilevel creates a 1bit bi-level image > The patch also fixes various Checkstyle issues in the classes I touched. = I've tried to preserve method backwards-compatibility. However, I've change= d PDFImageWriter.WriteImage to PDFImageWriter.writeImage. Method names shou= ld always start with a lower-case character. PageDrawer has similar problem= s which I didn't fix, however. > @Daniel: Please note that the changes makes the TestPDFToImage test case = fail because I've changed the default settings for PDFToImage to "rgb" and = the screen resolution (usually 96dpi). Before the settings were equivalent = to "-resolution 144 -color indexed". Furthermore, the output formats that s= upport a resolution value through standard ImageIO metadata will now contai= n the resolution information. That alone will make the reference PNGs diffe= rent even if I had set the default settings to the old settings and effecti= vely created the same images on the pixel level. You may need to decide on = the settings for the test and recreate the reference bitmaps. --=20 This message is automatically generated by JIRA. - You can reply to this email to add a comment to the issue online.