Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type FrameDisposal ¶
type FrameDisposal int
const ( FrameDisposalNone FrameDisposal = iota FrameDisposalDontDispose FrameDisposalRestoreBackground FrameDisposalRestorePrevious )
type GifImage ¶
type GifImage struct { //Texture is the current frame of the gif Texture r.Texture2D //Width is the width of a single frame Width int //Height is the height of a single frame Height int //Frames is the number of frames available Frames int //Timing is the delay (in 100ths of seconds) a frame has Timing []int //Disposal is the disposal for each frame Disposal []FrameDisposal // contains filtered or unexported fields }
GifImage represents a gif texture
func LoadGifFromFile ¶
LoadGifFromFile loads a new gif
func (*GifImage) CurrentFrame ¶
CurrentFrame returns the current frame index
func (*GifImage) CurrentTiming ¶
CurrentTiming gets the current timing for the current frame
func (*GifImage) GetRectangle ¶
GetRectangle gets a rectangle crop for a specified frame
func (*GifImage) NextFrame ¶
func (gif *GifImage) NextFrame()
NextFrame increments the frame counter and resets the timing buffer
func (*GifImage) Reset ¶
func (gif *GifImage) Reset()
Reset clears the last frame time and resets the current frame to zero
Click to show internal directories.
Click to hide internal directories.