Showing posts with label Glide. Show all posts
Showing posts with label Glide. Show all posts

Friday, September 12, 2014

Android: Image loading libraries Picasso vs Glide

This post is about image loading libraries, which could help us in avoiding complex codes.

Downloading of images, caching and reusing of images are know part of all the application and it became part of developers life. While doing this process, We need to consider few things...

  • Loading process should be asynchronously.
  • Image should display when it is loaded successfully, In case if it is not downloaded then placing some place holders.
  • Caching Image rather than downloading every time.

There are more libraries in the market which helps us in avoiding to do all these exercises and here I am going to discuss about Picasso and Glide. Where this two libraries looks similar in the way of implementation and Its easy to integrate in the middle of the application, since its a just a one line code to load image.

There are lot of features in the two libraries and few are listed below, where I can compare them easily.

Monday, September 8, 2014

Glide, an Android media loading library...

Recently I have came across new image loader library Glide from iosched Git Code

Glide

Glide is a fast and efficient open source media management framework for Android that wraps media decoding, memory and disk caching, and resource pooling into a simple and easy to use interface.

Glide's primary focus is on making scrolling any kind of a list of images as smooth and fast as possible, but Glide is also effective for almost any case where you need to fetch, resize, and display a remote image.

Implementation / Usage

When we see the implementation of Glide. It looks similar to the Picasso.

Let Looks the implementation of Picasso and Glide.

Picasso.with(this).load("http://i.imgur.com/DvpvklR.png").into(imageView);

Glide.with(this).load("http://i.imgur.com/DvpvklR.png").into(imageView);

Using the Picasso or Glide are easy and straight forward.

Advantage of Glide here is... Inbuilt it supports caching...

Let us assume, I am having two ImageView where one is loaded with Picasso and othere with Glide as shown below.