public final class GifDecoder extends Object
A decoder capable of processing a GIF data stream to render the graphics contained in it. This implementation follows the official GIF specification.
Example usage:
| 限定符和类型 | 类和说明 |
|---|---|
class |
GifDecoder.GifImage |
| 构造器和说明 |
|---|
GifDecoder() |
public static final GifDecoder.GifImage read(byte[] in) throws IOException
in - Raw image data as a byte[] arrayIOException - If the image violates the GIF specification or is truncated.public static final GifDecoder.GifImage read(InputStream is) throws IOException
is - Image data as input stream. This method will read from the
input stream's current position. It will not reset the
position before reading and won't reset or close the stream
afterwards. Call these methods before and after calling this
method as needed.IOException - If an I/O error occurs, the image violates the GIF
specification or the GIF is truncated.Copyright © 2018. All rights reserved.