Does anyone know if there is an API out there to scale pictures. Essentially I am allowing users to upload pictures which I'm storing on a database. If the picture the user is trying to store is not of proper size, i want programatically scale the picture to reduce the image size. Thanks, Ryan
SCJP 1.4, SCWCD
Java: The power, elegance, and simplicity of a hand grenade
Hi Ryan, You want the java.awt.Image class. When you have an image you can scale it like this:
The hints field suggests the manner in which the image will be scaled. You can look in API docs for the hints and their meaning. Hope this helps, Michael Morris
Any intelligent fool can make things bigger, more complex, and more violent. It takes a touch of genius - and a lot of courage - to move in the opposite direction. - Ernst F. Schumacher
If you want to look young and thin, hang around old, fat people. Or this tiny ad:
Building a Better World in your Backyard by Paul Wheaton and Shawn Klassen-Koop