简体   繁体   中英

Android gif animation with ImageView

I have a .gif file with four frames, i used Ion library for animation but it doesn't show good result. Because this library shows previous frame along with animation. How can i fix that?

Here is a link to a relevant question Display Animated GIF that has already been answered. Essentially, it says that you can display .gifs with the android.graphics.Movie class. It has been available from API level 1. check out this code linked here https://code.google.com/p/apidemos/source/browse/trunk/ApiDemos/src/com/example/android/apis/graphics/BitmapDecode.java#103 and from line 103 down there is an implementation of it opening an gif resource

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM