Picasso vs Glide


Test setup for comparing Glide and Picasso

A lot has happened in the world of image loading in the last few years.
I remember writing my own local image loader for the first version of Wallpaper Saver in 2013. It followed Googles guide for loading large bitmaps by only loading a scaled version of the bitmap into memory. I implemented a LRU memory cache and made sure that images were loaded asynchronously.

Since then we have founded Appdictive and Wallpaper Saver has been moved from my own developer account to our Appdictive developer account. In 2014 we released a new major version of Wallpaper Saver and almost every line of code was rewritten.

In this process I surveyed the most common image loading libraries that supported loading of local files. Universal Image Loader and Picasso were the most widely used solutions. I ended up implementing Picasso as it had the most clean implementation. I was quiet satisfied with the performance back then.

A year more and things have changed again. Now Glide seems to be the new black. Last week I had a few spare hours, so I decided to give it a try and test it out in Wallpaper Saver.

Shwooosssh. It was a near-magical experience.
First of all Glide comes with an API that is almost fully interchangeable with Picasso so changing from one library to the other took only about ten minutes!
Secondly. Due to Glides focus on speed over quality, images load super fast. Check out this blog by Nuuneoi to see some of the differences in memory and quality impact.

Comparing loading time in app

Glide had great reviews and a simple implementation, but actual performance was what mattered to us - so I decided to test it. The video below shows two similar devices (Nexus 5). They each run Wallpaper Saver with the same image files (59 PNG images with a total size of 274 mb) stored on external storage. The phone on the left is using Picasso. The phone on the right is using Glide. Both Picasso and Glide is used with default configuration.

I think that it is plain to see that Glide simply performs better.

This is how we invoke Picasso and Glide:

Picasso

Picasso.with(mContext).load(imageFile).priority(Picasso.Priority.HIGH).resize(width, height).into(image);

Glide

Glide.with(mContext).load(imageFile).override(width, height).into(image);

Note to reader

We are not in any way associated with either Glide or Picasso - we’re simply passionate Android developers sharing our results and experience with the two libraries. Feel free to leave your input / experiences in the comments below :)



By: Tobias Alrøe