From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 22410 invoked by alias); 13 Sep 2006 15:31:01 -0000 Received: (qmail 22402 invoked by uid 22791); 13 Sep 2006 15:31:00 -0000 X-Spam-Check-By: sourceware.org Received: from mx1.redhat.com (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org (qpsmtpd/0.31) with ESMTP; Wed, 13 Sep 2006 15:30:50 +0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11.20060308/8.12.11) with ESMTP id k8DFUmpN032096 for ; Wed, 13 Sep 2006 11:30:48 -0400 Received: from pobox.toronto.redhat.com (pobox.toronto.redhat.com [172.16.14.4]) by int-mx1.corp.redhat.com (8.12.11.20060308/8.12.11) with ESMTP id k8DFUZV4021955 for ; Wed, 13 Sep 2006 11:30:48 -0400 Received: from toddy.toronto.redhat.com (toddy.toronto.redhat.com [172.16.14.87]) by pobox.toronto.redhat.com (8.12.8/8.12.8) with ESMTP id k8DFUYm9012310 for ; Wed, 13 Sep 2006 11:30:34 -0400 Subject: FYI: RescaleOp fixlet From: Francis Kung To: mauve-patches@sources.redhat.com Content-Type: multipart/mixed; boundary="=-lf8EgygGW9BteIr2HyZp" Date: Wed, 13 Sep 2006 15:31:00 -0000 Message-Id: <1158161434.12454.100.camel@toddy.toronto.redhat.com> Mime-Version: 1.0 X-Mailer: Evolution 2.6.3 (2.6.3-1.fc5.5) X-IsSubscribed: yes Mailing-List: contact mauve-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: mauve-patches-owner@sourceware.org X-SW-Source: 2006/txt/msg00658.txt.bz2 --=-lf8EgygGW9BteIr2HyZp Content-Type: text/plain Content-Transfer-Encoding: 7bit Content-length: 287 Hi, The attached patch, already committed, updates (and fixes) sample value generation in the RescaleOp test. Cheers, Francis 2006-09-13 Francis Kung * gnu/testlet/java/awt/image/RescaleOp/filterRaster.java (simpleTests): Remove hard-coded max sample value. --=-lf8EgygGW9BteIr2HyZp Content-Disposition: attachment; filename=RescaleOp.diff Content-Type: text/x-patch; name=RescaleOp.diff; charset=UTF-8 Content-Transfer-Encoding: 7bit Content-length: 1064 Index: gnu/testlet/java/awt/image/RescaleOp/filterRaster.java =================================================================== RCS file: /cvs/mauve/mauve/gnu/testlet/java/awt/image/RescaleOp/filterRaster.java,v retrieving revision 1.1 diff -u -r1.1 filterRaster.java --- gnu/testlet/java/awt/image/RescaleOp/filterRaster.java 6 Sep 2006 16:00:32 -0000 1.1 +++ gnu/testlet/java/awt/image/RescaleOp/filterRaster.java 13 Sep 2006 15:26:49 -0000 @@ -28,7 +28,6 @@ import gnu.testlet.Testlet; import java.awt.image.BufferedImage; -import java.awt.image.DataBuffer; import java.awt.image.RescaleOp; import java.awt.image.WritableRaster; @@ -92,7 +91,7 @@ img.getRaster().setSample(1, 1, 0, 1500); op = new RescaleOp(100, 0, null); dstRast = op.filter(r, null); - double maxValue = Math.pow(2, DataBuffer.getDataTypeSize(r.getDataBuffer().getDataType())) - 1; + double maxValue = Math.pow(2, r.getSampleModel().getSampleSize(0)) - 1; harness.check(dstRast.getSample(1, 1, 0), maxValue); op = new RescaleOp(1, -2000, null); --=-lf8EgygGW9BteIr2HyZp--