hipmob / gifanimateddrawable Goto Github PK
View Code? Open in Web Editor NEWUse an animated GIF as an Android Drawable
Home Page: http://engineering.hipmob.com/2013/12/02/Showing-animated-gifs-on-Android/
Use an animated GIF as an Android Drawable
Home Page: http://engineering.hipmob.com/2013/12/02/Showing-animated-gifs-on-Android/
when start my application, i want to snimate my image using GIFanimateddrawable class... but its not working... my code is below,
try {
little = new GifAnimationDrawable(getResources().openRawResource(R.drawable.pentagonalicositetrahedroncw);
imageGIF.setImageDrawable(little);
((GifAnimationDrawable)imageGIF.getDrawable()).setVisible(true, true);
little.run();
little.setVisible(true, true);
} catch (NotFoundException e) {
// TODO Auto-generated catch block
e.printStackTrace();
} catch (IOException e) {
// TODO Auto-generated catch block
e.printStackTrace();
}
so we can use maven/gradle to get the latest version..
Tried integrating GiAnimationDrawable inside a Spannable string being set in a text view.
The image does not get displayed.
can someone make a gradle setup for this library?
It not animates the GIF as it has to on Android OS 'M' and above.
Your code is functional for Android OS below Marshmallow.
java.lang.OutOfMemoryError
at android.graphics.Bitmap.nativeCreate(Native Method)
at android.graphics.Bitmap.createBitmap(Bitmap.java:997)
at android.graphics.Bitmap.createBitmap(Bitmap.java:1021)
at com.yuilop.gif.GifDecoder.setPixels(GifDecoder.java:213)
at com.yuilop.gif.GifDecoder.readBitmap(GifDecoder.java:591)
at com.yuilop.gif.GifDecoder.readContents(GifDecoder.java:472)
at com.yuilop.gif.GifDecoder.complete(GifDecoder.java:256)
at com.yuilop.gif.GifAnimationDrawable$1.run(GifAnimationDrawable.java:86)
at java.lang.Thread.run(Thread.java:841)
Hello,
Thanks for your work on this lib
After generating .jar with build.xml and ant, i add this generated jar to my project.
But i have this 4 errors below...
Could you help me?
Thanks a lot!
The 4 errors :
Dx Uncaught translation error: java.lang.IllegalArgumentException: already added: Lcom/hipmob/gifanimationdrawable/GifAnimationDrawable$1;
Dx Uncaught translation error: java.lang.IllegalArgumentException: already added: Lcom/hipmob/gifanimationdrawable/GifAnimationDrawable;
Dx Uncaught translation error: java.lang.IllegalArgumentException: already added: Lcom/hipmob/gifanimationdrawable/GifDecoder$GifFrame;
Dx Uncaught translation error: java.lang.IllegalArgumentException: already added: Lcom/hipmob/gifanimationdrawable/GifDecoder;
Hi
I found 1 small bug
GifAnimationDrawable.java
there is
android.util.Log.v("GifAnimationDrawable", "===>Lead frame: ["+width+"x"+height+"; "+mGifDecoder.getDelay(0)+";"+mGifDecoder.getLoopCount()+"]");
height = mTmpBitmap.getHeight();
width = mTmpBitmap.getWidth();
should be different order
How to get frames as bitmaps in loop
Hi I created a demo app using this library and it ran expectedly on Android 4.4
However, no animation happens on Android L
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.