public class ImageUtils extends Object
| Modifier and Type | Class and Description |
|---|---|
static class |
ImageUtils.Direction
The Enum Direction.
|
| Constructor and Description |
|---|
ImageUtils() |
| Modifier and Type | Method and Description |
|---|---|
static BufferedImage |
concatenateImages(List<BufferedImage> imgCollection,
int width,
int height,
int imageType,
ImageUtils.Direction concatenationDirection)
Concatenate the given list of BufferedImage objects to one image and returns the concatenated
BufferedImage object.
|
static BufferedImage |
getResized(BufferedImage originalImage,
org.imgscalr.Scalr.Method scalingMethod,
org.imgscalr.Scalr.Mode resizeMode,
String formatName,
int targetWidth,
int targetHeight)
Resize the given BufferedImage and returns the resized BufferedImage.
|
static BufferedImage |
getResized(BufferedImage originalImage,
String formatName,
int targetWidth,
int targetHeight)
Resize the given BufferedImage and returns the resized BufferedImage.
|
static BufferedImage |
read(byte[] byteArray)
Gets the buffered image from the given byte array.
|
static byte[] |
resize(BufferedImage originalImage,
org.imgscalr.Scalr.Method scalingMethod,
org.imgscalr.Scalr.Mode resizeMode,
String formatName,
int targetWidth,
int targetHeight)
Resize the given image.
|
static byte[] |
resize(BufferedImage originalImage,
String formatName,
int targetWidth,
int targetHeight)
Resize the given BufferedImage.
|
static byte[] |
toByteArray(BufferedImage bi,
String formatName)
Converts the given BufferedImage to a byte array.
|
static String |
unweaveFrom(BufferedImage bufferedImage)
Unweave a secret message from the given
BufferedImage. |
static BufferedImage |
weaveInto(BufferedImage bufferedImage,
String message)
Weave the given secret message into the given
BufferedImage. |
public static BufferedImage concatenateImages(List<BufferedImage> imgCollection, int width, int height, int imageType, ImageUtils.Direction concatenationDirection)
imgCollection - the BufferedImage collectionwidth - the width of the image that will be returned.height - the height of the image that will be returned.imageType - type of the created imageconcatenationDirection - the direction of the concatenation.public static BufferedImage getResized(BufferedImage originalImage, org.imgscalr.Scalr.Method scalingMethod, org.imgscalr.Scalr.Mode resizeMode, String formatName, int targetWidth, int targetHeight) throws IOException
originalImage - the original imagescalingMethod - the scaling methodresizeMode - the resize modeformatName - the format nametargetWidth - the target widthtargetHeight - the target heightIOException - Signals that an I/O exception has occurred.public static BufferedImage getResized(BufferedImage originalImage, String formatName, int targetWidth, int targetHeight) throws IOException
originalImage - the original imageformatName - the format nametargetWidth - the target widthtargetHeight - the target heightIOException - Signals that an I/O exception has occurred.public static BufferedImage read(byte[] byteArray) throws IOException
byteArray - the byte arrayIOException - Signals that an I/O exception has occurred.public static byte[] resize(BufferedImage originalImage, org.imgscalr.Scalr.Method scalingMethod, org.imgscalr.Scalr.Mode resizeMode, String formatName, int targetWidth, int targetHeight)
originalImage - the original imagescalingMethod - the scaling methodresizeMode - the resize modeformatName - the format nametargetWidth - the target widthtargetHeight - the target heightpublic static byte[] resize(BufferedImage originalImage, String formatName, int targetWidth, int targetHeight)
originalImage - the original imageformatName - the format nametargetWidth - the target widthtargetHeight - the target heightpublic static byte[] toByteArray(BufferedImage bi, String formatName) throws IOException
bi - the biformatName - the format nameIOException - Signals that an I/O exception has occurred.public static String unweaveFrom(BufferedImage bufferedImage)
BufferedImage.bufferedImage - the buffered imagepublic static BufferedImage weaveInto(BufferedImage bufferedImage, String message)
BufferedImage.bufferedImage - the buffered imagemessage - the secret messageCopyright © 2007–2015 Alpha Ro Group UG (haftungsbeschrÀngt). All rights reserved.