glide icon indicating copy to clipboard operation
glide copied to clipboard

Bug: can't have support animation (and sometimes even normal image) of GIF, AVIF, WEBP at the same time

Open AndroidDeveloperLB opened this issue 1 year ago • 0 comments

I use these:

//    https://github.com/bumptech/glide https://github.com/zjupure/GlideWebpDecoder
// https://bumptech.github.io/glide/doc/download-setup.html#kotlin---ksp   https://bumptech.github.io/glide/int/avif.html
val glideVersion = "4.16.0"
implementation("com.github.zjupure:webpdecoder:2.6.${glideVersion}")
implementation("com.github.bumptech.glide:glide:${glideVersion}")
ksp ("com.github.bumptech.glide:ksp:${glideVersion}")
implementation("com.github.bumptech.glide:avif-integration:${glideVersion}")

I've noticed that for some reason, I can't support animation of each of them , always. Not only that, but I think in some cases, loading simple images might have bad results (not showing, or having bad decoding). Sometimes even animated GIF stops playing and only has the first frame....

This was tested on Pixel 6 with Android 15, and on emulator with API 30.

Attached sample to prove that:

  1. When all exist, only animated WEBP is showing. The rest are static.
  2. When AVIF is missing, on Android 13 and below of course it won't work (AVIF is supported only from Android 14) and it actually causes a crash without letting me handle it via the listener. Removing the AVIF code, Android 13 and below can handle both animations of WEBP and GIF just fine. On Android 15, the animated AVIF won't work. Animated GIF and animated WEBP do appear fine though. Also even normal AVIF images decoding might result in weird artefacts.
  3. When WEBP is missing, all images are static. No animation at all.

Please fix this. I want to use various kinds of images and animations.

Glide Test.zip

AndroidDeveloperLB avatar Feb 10 '25 11:02 AndroidDeveloperLB