Lines Matching refs:gif
5 // Package gif implements a GIF image decoder and encoder.
7 // The GIF specification is at http://www.w3.org/Graphics/GIF/spec-gif89a.txt.
8 package gif
21 errNotEnough = errors.New("gif: not enough image data")
22 errTooMuch = errors.New("gif: too much image data")
23 errBadPixel = errors.New("gif: invalid pixel value")
66 // decoder is the type used to decode a GIF file.
96 // blockReader parses the block structure of GIF image data, which
136 // decode reads a GIF image from r and stores the result in d.
177 return errors.New("gif: no color table")
193 return fmt.Errorf("gif: pixel size in decode out of range: %d", litWidth)
215 // See https://golang.org/issue/9856 for an example GIF.
259 return fmt.Errorf("gif: unknown block type: 0x%.2x", c)
271 return fmt.Errorf("gif: can't recognize format %s", d.vers)
290 return nil, fmt.Errorf("gif: short read on color table: %s", err)
321 return fmt.Errorf("gif: unknown extension 0x%.2x", extension)
350 return fmt.Errorf("gif: can't read graphic control: %s", err)
364 return nil, fmt.Errorf("gif: can't read image descriptor: %s", err)
377 return nil, errors.New("gif: frame bounds larger than image bounds")
395 // interlacing represents the set of scans in an interlaced GIF image.
421 // Decode reads a GIF image from r and returns the first embedded
431 // GIF represents the possibly multiple images stored in a GIF file.
432 type GIF struct {
448 // EncodeAll, and implies that the overall GIF's width and height equals
456 // DecodeAll reads a GIF image from r and returns the sequential frames
458 func DecodeAll(r io.Reader) (*GIF, error) {
463 gif := &GIF{
475 return gif, nil
478 // DecodeConfig returns the global color model and dimensions of a GIF image
493 image.RegisterFormat("gif", "GIF8?a", Decode, DecodeConfig)