Package com.idrsolutions.image.scale
Class QualityThumbnail
java.lang.Object
com.idrsolutions.image.JDeliImage
com.idrsolutions.image.scale.QualityThumbnail
public class QualityThumbnail
extends com.idrsolutions.image.JDeliImage
Class uses Lancsoz3 algorithm to generate good quality thumbnails or scaled images.
Example:
BufferedImage thumbnailImage = QualityThumbnail.getScaledImage(sourceImage,64,64);
-
Field Summary
Fields inherited from class com.idrsolutions.image.JDeliImage
bb
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionstatic BufferedImage
getScaledImage
(BufferedImage sourceImage, int expectedWidth, int expectedHeight) Generates a good quality thumbnail of an imageMethods inherited from class com.idrsolutions.image.JDeliImage
optimiseImage
-
Constructor Details
-
QualityThumbnail
public QualityThumbnail()
-
-
Method Details
-
getScaledImage
public static BufferedImage getScaledImage(BufferedImage sourceImage, int expectedWidth, int expectedHeight) Generates a good quality thumbnail of an image- Parameters:
sourceImage
- input image to scaleexpectedWidth
- width you would like the output thumbnail to haveexpectedHeight
- height you would like the output thumbnail to have- Returns:
- thumbnail the generated thumbnail of the source image
-