public int read(BufferedInputStream is) {
        init();
        if (is != null) {
            in = is;
            readHeader();
            if (!err()) {
                readContents();
                if (frameCount < 0) {
                    status = STATUS_FORMAT_ERROR;
                }
            }
        } else {
            status = STATUS_OPEN_ERROR;
        }
        try {
            is.close();
        } catch (IOException e) {
        }
        return status;
    }
Reads GIF image from stream

@param is containing GIF file.
@return read status code (0 = no errors)
plugins/base-plugin/src/main/java/com/github/hui/quick/plugin/base/gif/GifDecoder.java