public final class SaImageConverter extends Object
Modifier and Type | Class and Description |
---|---|
static class |
SaImageConverter.ImageFormat
Image formats available for conversion.
|
Modifier and Type | Method and Description |
---|---|
static BufferedImage |
bmpToBufferedImage(byte[] bmp,
SaImageConverter.ImageFormat format)
Converts a bitmap to a BufferedImage.
|
static BufferedImage |
dibToBufferedImage(byte[] dibBytes,
SaImageConverter.ImageFormat format)
Converts a device independent bitmat (DIB) to a BufferedImage.
|
static BufferedImage |
makeTransparent(BufferedImage image,
Color color)
Makes the given image transparent.
|
public static BufferedImage bmpToBufferedImage(byte[] bmp, SaImageConverter.ImageFormat format) throws IOException, SaImageConverterException
bmp
- bitmapformat
- format for the BufferedImageIOException
- io exceptionSaImageConverterException
- image conversion failedpublic static BufferedImage dibToBufferedImage(byte[] dibBytes, SaImageConverter.ImageFormat format) throws IOException, SaImageConverterException
dibBytes
- dib bytesformat
- format for the BufferedImageIOException
- io exceptionSaImageConverterException
- conversion failedpublic static BufferedImage makeTransparent(BufferedImage image, Color color)
RGBImageFilter
filter to convert pixel to transparent.image
- the image to turn transparencycolor
- the color to turn pixels transparentCopyright © 2016 SAPERION AG. All rights reserved.