Picasso, Glide, or Fresco

March 2021

I made a test with loading ~100mb of images (32 individual bitmaps) from /res/drawable-xxhdpi folder. I didn’t use imageView.setImageResource cause it loads images synchronously and blocks the UI thread. Overall, it takes ~50 minutes on Galaxy S3 to load everything. So the results:

  1. Fresco loads images also synchronously. Probably, it uses imageView.setImageResource under the hood.
  2. Glide is better. But it’s prefetching algorithm is somewhat different from what I expect. It seems like I’m always scrolling an empty RecyclerView, instead of seeing images.
  3. Picasso worked the best:
    1. Async image loading
    2. Less amount of code.
    3. Similarly to Glide, there’re no non-standard UI components (in comparison with Fresco).
    4. Nice loading prioritisation. In Splash activity I start prefetching, then, after ~5 seconds, on my RecyclerView activity I’m loading images with a higher priority. Thus, a user can scroll the list smoothly, while the prefetching is being loaded in the background.

So, finally, I adjusted the caching size to ~80% of free mem. It allowed to cache everything. Everything! So it loads super smoothly, it works super smoothly and it takes almost no code.

Leave a Reply

Your email address will not be published. Required fields are marked *