public class ImageScaler extends Object
Constructor and Description |
---|
ImageScaler() |
Modifier and Type | Method and Description |
---|---|
RenderedImage |
getSelectedImageData(BufferedImage sourceImage,
Selection crop,
int size)
Creates an image consisting of the given selection of the source image rescaled to a square with the given size.
|
public RenderedImage getSelectedImageData(BufferedImage sourceImage, Selection crop, int size)
sourceImage
- the image source to crop and scale from.crop
- the subrectangle to use, usually square to avoid aspect ratio changes.size
- the desired size of the edge of the resulting square image.Copyright © 2002-2021 Atlassian. All Rights Reserved.