Hassel-free Image Loading Libraries

In this part, we are going to talk about some the best Image Loading Libraries for loading images.

It is always not about downloading image from remote location. You also have to think of implementing image caching logic in order to provide a seamless user experience.

Many a times we may have to load multiple images say 50+ with bigger size (640×380) asynchronously in List View or Gird View which might result in OutOfMemory error. Even i have faced this issue and have tried to various ways to fix this, but was not so effective.After doing lot of research i found that there are libraries which will load images asynchronously, and cache images as well.

1) Picasso 

  • Picasso simplifies the process of loading images from external urls and display on your application.
  •  Automatic image caching.
  • Handling Image View recycling.
  • Efficient Memory usage with minimal memory use, also takes care of Out of Memory Exception.
  • Automatic job cancellation in lists where views are re-used.
  • It even does “Image Fade In” which is popular now a days.
  • Batching UI Updates and improve UI responsiveness.
  • Debug indicators to check if its from Network,Disk or Cache.

 Usage :

In Adapter’s getView() :


Resource Loading :

Resources, assets, files, content providers are all supported as image sources.

Picasso.with(context).load(new File(…)).into(imageView3);

 Read More :


2) Volley : 

  • Developed and Maintained by Android Dev Team.
  • Asynchronous Networking Library.
  • NetworkImageView is meant to be a direct replacement for the standard ImageView in scenarios when your image resource is coming from a network location (i.e. URL).

Usage :


Becomes :


Setting up the Image Loader Class :

private RequestQueue mRequestQueue;
private ImageLoader mImageLoader;

In constructor or onCreate() initialize the objects :

mRequestQueue = Volley.newRequestQueue(context);
mImageLoader = new ImageLoader(mRequestQueue, new ImageLoader.ImageCache() {
private final LruCache<String, Bitmap> mCache = new LruCache<String, Bitmap>(10);
public void putBitmap(String url, Bitmap bitmap) {
mCache.put(url, bitmap);
public Bitmap getBitmap(String url) {
return mCache.get(url);

Loading an Image into Image View :

NetworkImageView networkImageView = (NetworkImageView)view.findViewById(R.id.image_view);


Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )


Connecting to %s