public class FileEncodedImage extends EncodedImage
Modifier and Type | Method and Description |
---|---|
static FileEncodedImage |
create(String fileName,
InputStream i,
int width,
int height)
Creates an encoded image that maps to a local file thus allowing to
seamlessly fetch files as needed.
|
static FileEncodedImage |
create(String fileName,
int width,
int height)
Creates an encoded image that maps to a local file thus allowing to
seamlessly fetch files as needed.
|
static FileEncodedImage |
create(String fileName,
int width,
int height,
boolean keep)
Creates an encoded image that maps to a local file thus allowing to
seamlessly fetch files as needed.
|
byte[] |
getImageData()
Returns the byte array data backing the image allowing the image to be stored
and discarded completely from RAM.
|
asyncLock, create, create, create, create, create, createFromImage, createFromRGB, createMulti, drawImage, drawImage, getGraphics, getHeight, getImage, getInternal, getWidth, isAnimation, isLocked, isOpaque, lock, modifyAlpha, modifyAlpha, resetCache, rotate, scale, scaled, scaledEncoded, scaledHeight, scaledSmallerRatio, scaledWidth, subImage, toRGB, unlock
addActionListener, animate, applyMask, applyMask, applyMaskAutoScale, createImage, createImage, createImage, createImage, createImage, createImage, createImage, createIndexed, createMask, createSVG, dispose, exifRotation, exifRotation, exifRotation, fill, fireChangedEvent, flipHorizontally, flipVertically, getExifOrientationTag, getExifOrientationTag, getImageName, getRGB, getRGB, getRGBCached, getSVGDocument, isAlphaMutableImageSupported, isJPEG, isPNG, isSVG, isSVGSupported, mirror, modifyAlphaWithTranslucency, removeActionListener, requiresDrawImage, rotate180Degrees, rotate270Degrees, rotate90Degrees, scaledLargerRatio, setImageName
public byte[] getImageData()
getImageData
in class EncodedImage
public static FileEncodedImage create(String fileName, int width, int height)
fileName
- the name of the filewidth
- the width of the file or -1 if unknown (notice that this will improve performance)height
- the height of the file or -1 if unknown (notice that this will improve performance)public static FileEncodedImage create(String fileName, InputStream i, int width, int height) throws IOException
fileName
- the name of the filei
- input stream from which to create the filewidth
- the width of the file or -1 if unknown (notice that this will improve performance)height
- the height of the file or -1 if unknown (notice that this will improve performance)IOException
public static FileEncodedImage create(String fileName, int width, int height, boolean keep)
fileName
- the name of the filewidth
- the width of the file or -1 if unknown (notice that this will improve performance)height
- the height of the file or -1 if unknown (notice that this will improve performance)keep
- if set to true keeps the file in RAM once loaded