Loading local images thumbnails
- Dominant language
- Java
- Stars
- 35k
- Forks
- 6.2k
- Avg merge
- 1d 11h
- Merged PRs (30d)
- 8
Description
I was recently trying to use [thumbnail API](https://bumptech.github.io/glide/javadocs/400/com/bumptech/glide/RequestBuilder.html#thumbnail-com.bumptech.glide.RequestBuilder-) to load local media thumbnails which weren't actually loading a thumbnail but the full image. By exploring glide codebase I found that Glide is using [ThumbFetcher](https://github.com/bumptech/glide/blob/master/library/src/main/java/com/bumptech/glide/load/data/mediastore/ThumbFetcher.java) to load media store thumbnails which is basically querying the thumbnails table as in [here](https://github.com/bumptech/glide/blob/master/library/src/main/java/com/bumptech/glide/load/data/mediastore/ThumbFetcher.java#L142). MediaStore.Images.Thumbnails is already deprecated and thumbnail generation is currently done using a different flow which doesn't insert anything in the thumbnails table anymore, which would lead to having the thumbFetcher return null.
I believe the current implementation of ThumbFetcher should shift towards calling ContentResolver.loadThumbnail or ContentResolver.openTypedAssetFile to make sure that glide is handling the media store thumbnail requests correctly.
Please let me know your thoughts!
Contributor guide
Assessment
This issue has not been assessed yet.