public class GIFImageLoader2 extends ImageLoaderImpl
formatDescription, lastPercentDone, listeners
Constructor and Description |
---|
GIFImageLoader2(InputStream input) |
Modifier and Type | Method and Description |
---|---|
void |
dispose()
Disposes of any resources (such as native libraries) held by this loader.
|
ImageFrame |
load(int imageIndex,
int width,
int height,
boolean preserveAspectRatio,
boolean smooth)
Loads the image at a given index in an image stream.
|
addListener, emitWarning, getFormatDescription, removeListener, updateImageMetadata, updateImageProgress
public GIFImageLoader2(InputStream input) throws IOException
IOException
public ImageFrame load(int imageIndex, int width, int height, boolean preserveAspectRatio, boolean smooth) throws IOException
ImageLoader
null
will be returned.imageIndex
- the zero-relative index of the image to load.width
- the desired image width. If non-positive,
an IllegalArgumentException
will be thrown.height
- the desired image height. If non-positive,
an IllegalArgumentException
will be thrown.preserveAspectRatio
- whether to preserve the width-to-height ratio
of the image.smooth
- whether to use a smooth downscaling algorithm.null
on error.IOException
public void dispose()
ImageLoader
Copyright © 2020. All rights reserved.