Export to GitHub

java-image-scaling - issue #8

ProgressListener.notifyProgress(float fraction) gets values up to about 191 for fraction, but it should max be 1.0


Posted on Sep 11, 2009 by Helpful Cat

What steps will reproduce the problem? 1. Just implement a ProgressListener and print out the values of fraction

What is the expected output? What do you see instead? Expected Output: 0.0 to 1.0, I see values up to about 191.

What version of the product are you using? On what operating system? Version 0.8.1 (jar), resizing Images of about 4000x2500

Please provide any additional information below. Code: BufferedImage img = ImageIO.read(file); ResampleOp resizeOp = new ResampleOp(DimensionConstrain.createMaxDimension(300, 300, true)); if (pl != null) resizeOp.addProgressListener(pl); BufferedImage thumb = resizeOp.filter(img, null);

And in the ProgressListener implementation: public void notifyProgress(float progress) { System.out.println("Progress: " + progress); }

Comment #1

Posted on Sep 11, 2009 by Helpful Kangaroo

(No comment was entered for this change.)

Comment #2

Posted on Sep 12, 2009 by Helpful Kangaroo

Fixed and committed. Fix will be available in 0.8.2

Status: Done

Labels:
Type-Defect Priority-Medium