Class BilinearResizer
- java.lang.Object
-
- net.coobird.thumbnailator.resizers.AbstractResizer
-
- net.coobird.thumbnailator.resizers.BilinearResizer
-
- All Implemented Interfaces:
Resizer
public class BilinearResizer extends AbstractResizer
Image resizer class using bilinear interpolation for the resizing operation.
-
-
Field Summary
-
Fields inherited from class net.coobird.thumbnailator.resizers.AbstractResizer
KEY_INTERPOLATION, RENDERING_HINTS, UNMODIFIABLE_RENDERING_HINTS
-
-
Constructor Summary
Constructors Constructor Description BilinearResizer()Instantiates aBilinearResizerwith default rendering hints.BilinearResizer(java.util.Map<java.awt.RenderingHints.Key,java.lang.Object> hints)Instantiates aBilinearResizerwith the specified rendering hints.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidresize(java.awt.image.BufferedImage srcImage, java.awt.image.BufferedImage destImage)Resizes an image using bilinear interpolation.-
Methods inherited from class net.coobird.thumbnailator.resizers.AbstractResizer
createGraphics, getRenderingHints, performChecks
-
-
-
-
Constructor Detail
-
BilinearResizer
public BilinearResizer()
Instantiates aBilinearResizerwith default rendering hints.
-
BilinearResizer
public BilinearResizer(java.util.Map<java.awt.RenderingHints.Key,java.lang.Object> hints)
Instantiates aBilinearResizerwith the specified rendering hints.- Parameters:
hints- Additional rendering hints to apply.
-
-
Method Detail
-
resize
public void resize(java.awt.image.BufferedImage srcImage, java.awt.image.BufferedImage destImage) throws java.lang.NullPointerExceptionResizes an image using bilinear interpolation.
If the source and/or destination image is
null, then aNullPointerExceptionwill be thrown.- Specified by:
resizein interfaceResizer- Overrides:
resizein classAbstractResizer- Parameters:
srcImage- The source image.destImage- The destination image.- Throws:
java.lang.NullPointerException- When the source and/or the destination image isnull.
-
-