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

    Constructors
    Constructor
    Description
     
  • Method Summary

    Modifier and Type
    Method
    Description
    getScaledImage(BufferedImage sourceImage, int expectedWidth, int expectedHeight)
    Generates a good quality thumbnail of an image

    Methods inherited from class com.idrsolutions.image.JDeliImage

    optimiseImage

    Methods inherited from class java.lang.Object

    equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
  • 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 scale
      expectedWidth - width you would like the output thumbnail to have
      expectedHeight - height you would like the output thumbnail to have
      Returns:
      thumbnail the generated thumbnail of the source image