gif - The Go Programming Language

Golang

Package gif

import "image/gif"
Overview
Index

Overview ?

Overview ?

Package gif implements a GIF image decoder.

The GIF specification is at http://www.w3.org/Graphics/GIF/spec-gif89a.txt.

Index

func Decode(r io.Reader) (image.Image, error)
func DecodeConfig(r io.Reader) (image.Config, error)
type GIF
    func DecodeAll(r io.Reader) (*GIF, error)

Package files

reader.go

func Decode

func Decode(r io.Reader) (image.Image, error)

Decode reads a GIF image from r and returns the first embedded image as an image.Image.

func DecodeConfig

func DecodeConfig(r io.Reader) (image.Config, error)

DecodeConfig returns the global color model and dimensions of a GIF image without decoding the entire image.

type GIF

type GIF struct {
    Image     []*image.Paletted // The successive images.
    Delay     []int             // The successive delay times, one per frame, in 100ths of a second.
    LoopCount int               // The loop count.
}

GIF represents the possibly multiple images stored in a GIF file.

func DecodeAll

func DecodeAll(r io.Reader) (*GIF, error)

DecodeAll reads a GIF image from r and returns the sequential frames and timing information.