Enable animated GIFs in stock browser

Search This thread

FMXP

Senior Member
Jul 30, 2007
224
91
I notice that animated GIFs are still not enabled by default in the browser after the Froyo update. Does anyone know how to do this?
 

generic.imitation

Senior Member
Feb 5, 2009
233
70
my friends droid 1 has the froyo update and it has animated GIFs... this has been my biggest complaint about the OS. I go to spikedhumor.com and I enjoy my daily GIFs, but can only (semi) enjoy them because the wife is present :rolleyes:

I hope this is in the final build of Froyo.

I have been posting on the google code site about this issue since early 2009.

one of the google reps on the page replied with a way to implement it, and I posted it on this site elsewhere a while back. I'll repost it here with a link to the source.

If you want to work around this with your own Android build, you'll need to modify C++ code, rebuild, and
reflash your phone. You'll need to make two fixes to the released sources.

1) edit the function should_use_animated_gif() in
external/webkit/WebCore/platform/graphics/android/ImageSourceAndroid.cpp (around line 217). Return true
to animate gifs.

2) Change setRGBA() in /WebCore/platform/image-decoders/ImageDecoder.h (around line 173) to call
*dest = SkPackARGB32(a, r, g, b);
instead of
*dest = (a << 24 | r << 16 | g << 8 | b);

With these changes, gifs will animated correctly on large memory devices like Droid and Nexus One.

There's no code path for animating gifs in arbitrary applications like Gallery, except by rewriting it to host a
WebView modded as described above.

http://code.google.com/p/android/issues/detail?id=3422#c134
 

Enndr

Senior Member
Apr 7, 2010
269
1
Cincinnati
Animated GIFs have nothing to do with flash. Nothing whatsoever.

Animated GIFs are several images (GIFs) contained within the single shell GIF.
They typically trigger browsers to play it which makes it look animated.

This is similar to how the boot animations and some live backgrounds are done on Android devices. Except they do it with PNG files.
 

uptheforest

Member
Oct 19, 2009
13
0
i havent gone to any .gif sites but the forums that i visit regularly that have .gif avatars play just fine since the update to 2.2
 

Bifuu

New member
Aug 27, 2010
1
0
Running unrooted 2.2 on my dX gives me Animated gifs. Default settings in stock browser, not sure if anything else i did may have enabled them but basically they just work.

Feel free to point me to look at some settings for you guys if you want to try to make it work on your phones, im new to android (Smart phones in general actually) so ill need some points.