Open wangxuyang518 opened 2 years ago
Yes AVIF decoder is dependent on the CPU. But ideally it should not take that long on any modern device.
Do you have a sample image that takes 5-10s to load? If so, i can try and take a look at what's going on. Also, which device are you trying this on?
no explicit sample ,decoding long time is a random behavior . we also consider whether the avif file size affects the decoding. but at present, no rules have been found
Android 12 introduces support for AVIF. Does this mean Glide can now take advantage of hardware acceleration (if available) to decode AVIFs?
Android 12 introduces support for AVIF. Does this mean Glide can now take advantage of hardware acceleration (if available) to decode AVIFs?
Glide's AVIF integration is software only. So if you use that decoding will happen in software.
If you are using Glide without the AVIF integration, then AVIF images on Android 12+ will be decoded using the Android platform's decoder (which may be software or hardware depending on what the platform does). As far as i am aware, the platform does not use hardware AV1 decoder for AVIF decoding and uses software only. It is controlled by a system property which is not set by default on devices that i checked (Pixel 6, Pixel 7).
avif decoder is dependent on cpu , sometimes this decode process is too long 、sush as spending 10s or 5s
Is there a good optimization scheme?