Hi! I have the following code to downscale images:
// Do the scalingBufferedImage reducedImage = new BufferedImage(newX, newY, BufferedImage.TYPE_INT_RGB);
Graphics2D g = reducedImage.createGraphics();g.setRenderingHint(RenderingHints.KEY_INTERPOLATION, RenderingHints.VALUE_INTERPOLATION_BICUBIC); g.setRenderingHint(RenderingHints.KEY_ANTIALIASING, RenderingHints.VALUE_ANTIALIAS_ON); g.setRenderingHint(RenderingHints.KEY_RENDERING, RenderingHints.VALUE_RENDER_SPEED);
NSLog.out.appendln("Drawing image with original dimensions " +
originalImage.getWidth() + ", " + originalImage.getHeight()
+ " with size " + newX + ", " + newY ); */
g.drawImage(originalImage, 0, 0, newX, newY, 0, 0,
originalImage.getWidth(), originalImage.getHeight(), null);
g.dispose();The log is: INFO 00:27:16 (NSLog :38) -Drawing image with original dimensions 3072, 2304 with size 267, 200
This took about a second to process in my Powerbook on Tiger. I migrated to Leopard, and this is taking... well... forever. I waited several minutes and it's still sucking up my CPU. Shark says it's taking a lot of time in color conversion stuff:
<<inline: pastedGraphic.png>>
I have no ideia why. It's the same image and the same code. Only the OS has changed. Another Leopard bug?
Any ideias? Yours Miguel Arroz Miguel Arroz http://www.terminalapp.net http://www.ipragma.com
smime.p7s
Description: S/MIME cryptographic signature
_______________________________________________ Do not post admin requests to the list. They will be ignored. Webobjects-dev mailing list ([email protected]) Help/Unsubscribe/Update your Subscription: http://lists.apple.com/mailman/options/webobjects-dev/archive%40mail-archive.com This email sent to [EMAIL PROTECTED]
