Using GIF Animations ?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
User avatar
nightvenom
Prole
Posts: 36
Joined: Sat Aug 16, 2008 3:07 pm

Using GIF Animations ?

Post by nightvenom »

Is it possible to use GIF animations in love ?

:)

And how might one code this ?
User avatar
Merkoth
Party member
Posts: 186
Joined: Mon Feb 04, 2008 11:43 pm
Location: Buenos Aires, Argentina

Re: Using GIF Animations ?

Post by Merkoth »

If your idea is to directly load a GIF file and play it I don't think it's possible. Right know, LÖVE can extract the frames from a plain image and then draw the correct image at any given moment (depending on the animation speed/lenght). You can also add frames to an already existing animation with the AddFrame() method IIRC. But don't take my word on that :oops:

A typical animation image looks something like this:
Image

Regarding code, there's a fine tutorial on animations here: http://love2d.org/index.php?page=tutorial&id=006
User avatar
nightvenom
Prole
Posts: 36
Joined: Sat Aug 16, 2008 3:07 pm

Re: Using GIF Animations ?

Post by nightvenom »

k, i've seen and play around with the tutorial, so i'm trying to get a friend to just send me the frames :)

I'll test and see if that works properly.
Post Reply

Who is online

Users browsing this forum: Bing [Bot] and 216 guests