Return-Path: X-Original-To: apmail-commons-issues-archive@minotaur.apache.org Delivered-To: apmail-commons-issues-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id BA6AF1786B for ; Tue, 6 Jan 2015 20:58:43 +0000 (UTC) Received: (qmail 77623 invoked by uid 500); 6 Jan 2015 20:58:44 -0000 Delivered-To: apmail-commons-issues-archive@commons.apache.org Received: (qmail 77551 invoked by uid 500); 6 Jan 2015 20:58:44 -0000 Mailing-List: contact issues-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: issues@commons.apache.org Delivered-To: mailing list issues@commons.apache.org Received: (qmail 77518 invoked by uid 99); 6 Jan 2015 20:58:44 -0000 Received: from arcas.apache.org (HELO arcas.apache.org) (140.211.11.28) by apache.org (qpsmtpd/0.29) with ESMTP; Tue, 06 Jan 2015 20:58:44 +0000 Date: Tue, 6 Jan 2015 20:58:44 +0000 (UTC) From: "Josh Highley (JIRA)" To: issues@commons.apache.org Message-ID: In-Reply-To: References: Subject: [jira] [Commented] (IMAGING-141) BufferedImage from TIFF is always 24 or 32 bpp MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit X-JIRA-FingerPrint: 30527f35849b9dde25b450d4833f0394 [ https://issues.apache.org/jira/browse/IMAGING-141?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14266754#comment-14266754 ] Josh Highley commented on IMAGING-141: -------------------------------------- Depending on how it's stored, there could also be an 8 fold increase memory usage. All other imaging libraries I've used output a binary BufferedImage for 1bpp input. If performance is truly an issue, make the default to match the bpp, but allow programmers to 'upscale' the type. > BufferedImage from TIFF is always 24 or 32 bpp > ---------------------------------------------- > > Key: IMAGING-141 > URL: https://issues.apache.org/jira/browse/IMAGING-141 > Project: Commons Imaging > Issue Type: Bug > Components: Format: TIFF > Reporter: Josh Highley > Fix For: Patch Needed > > > When getting a BufferedImage from a TIFF, TiffImageParser.getBufferedImage gets the TIFF's BPP from the TIFF tags, but at the end ImageBuilder.getBufferedImage() will always set the BufferedImage ColorModel BPP to 32 for images with alpha and 24 bpp otherwise. Many TIFFs are 1 bpp (G3 and G4) so the BufferedImage should also be 1 bpp. -- This message was sent by Atlassian JIRA (v6.3.4#6332)