Return-Path: X-Original-To: apmail-commons-commits-archive@minotaur.apache.org Delivered-To: apmail-commons-commits-archive@minotaur.apache.org Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by minotaur.apache.org (Postfix) with SMTP id 6250610A30 for ; Thu, 24 Oct 2013 00:23:00 +0000 (UTC) Received: (qmail 577 invoked by uid 500); 24 Oct 2013 00:23:00 -0000 Delivered-To: apmail-commons-commits-archive@commons.apache.org Received: (qmail 528 invoked by uid 500); 24 Oct 2013 00:23:00 -0000 Mailing-List: contact commits-help@commons.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@commons.apache.org Delivered-To: mailing list commits@commons.apache.org Received: (qmail 519 invoked by uid 99); 24 Oct 2013 00:23:00 -0000 Received: from nike.apache.org (HELO nike.apache.org) (192.87.106.230) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Oct 2013 00:23:00 +0000 X-ASF-Spam-Status: No, hits=-2000.0 required=5.0 tests=ALL_TRUSTED X-Spam-Check-By: apache.org Received: from [140.211.11.4] (HELO eris.apache.org) (140.211.11.4) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 24 Oct 2013 00:22:57 +0000 Received: from eris.apache.org (localhost [127.0.0.1]) by eris.apache.org (Postfix) with ESMTP id C3DE223888D7; Thu, 24 Oct 2013 00:22:36 +0000 (UTC) Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Subject: svn commit: r1535225 - /commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java Date: Thu, 24 Oct 2013 00:22:36 -0000 To: commits@commons.apache.org From: ggregory@apache.org X-Mailer: svnmailer-1.0.9 Message-Id: <20131024002236.C3DE223888D7@eris.apache.org> X-Virus-Checked: Checked by ClamAV on apache.org Author: ggregory Date: Thu Oct 24 00:22:35 2013 New Revision: 1535225 URL: http://svn.apache.org/r1535225 Log: The static method createPackedRaster(int, int, int, int[], Point) from the type Raster should be accessed directly. Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java Modified: commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java URL: http://svn.apache.org/viewvc/commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java?rev=1535225&r1=1535224&r2=1535225&view=diff ============================================================================== --- commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java (original) +++ commons/proper/imaging/trunk/src/main/java/org/apache/commons/imaging/formats/jpeg/decoder/JpegDecoder.java Thu Oct 24 00:22:35 2013 @@ -19,6 +19,7 @@ import java.awt.image.BufferedImage; import java.awt.image.ColorModel; import java.awt.image.DataBuffer; import java.awt.image.DirectColorModel; +import java.awt.image.Raster; import java.awt.image.WritableRaster; import java.io.ByteArrayInputStream; import java.io.IOException; @@ -95,13 +96,13 @@ public class JpegDecoder extends BinaryF if (sofnSegment.numberOfComponents == 3) { colorModel = new DirectColorModel(24, 0x00ff0000, 0x0000ff00, 0x000000ff); - raster = WritableRaster.createPackedRaster(DataBuffer.TYPE_INT, + raster = Raster.createPackedRaster(DataBuffer.TYPE_INT, sofnSegment.width, sofnSegment.height, new int[] { 0x00ff0000, 0x0000ff00, 0x000000ff }, null); } else if (sofnSegment.numberOfComponents == 1) { colorModel = new DirectColorModel(24, 0x00ff0000, 0x0000ff00, 0x000000ff); - raster = WritableRaster.createPackedRaster(DataBuffer.TYPE_INT, + raster = Raster.createPackedRaster(DataBuffer.TYPE_INT, sofnSegment.width, sofnSegment.height, new int[] { 0x00ff0000, 0x0000ff00, 0x000000ff }, null); // FIXME: why do images come out too bright with CS_GRAY?