redwarp / gifdecoder

An implementation of a gif decoder written 100% in Kotlin, plus an associated Drawable for Android
Apache License 2.0
47 stars 6 forks source link

Advance will now calculate the current frame #16

Closed redwarp closed 2 years ago

redwarp commented 2 years ago

Implements #15 : The calculation of the frame will now occur when calling the advance() method, and getCurrentFrame will simply copy the pixel buffer. getFrame(index) will now internally call advance to make sure that each frame is processed in sequence.

So, the new flow would be: getFrame (once, twice, as many as wanted), then advance, then getframe, then advance.