views:

68

answers:

1

In my app I need to download a lot of images for data in a ListView. I do lazy loading and it works rather fast, but still there is a 1-3 secs delay before the first image shows up. My research in the delay shows that the data transfer takes 50% of the time.

Now, I believe that If I could do incremental loading of the images, I would be able to show half an image after just 75% of the delay, which is quite good.

I use Drawable.createFromStream which uses BitmapFactory.decodeResourceStream internally. But even though it takes a stream, it doesn't paint anything before all data is downloaded and decoded.

Do you know a way to load and paint images incrementally with the default Android lib? Or perhaps a good independent one out there?

Screenshot of an ImageDownloader app

A: 

For the download process, check WebImageView by DroidFu.

Macarse
It does show a nice loading icon, but I'm not sure whether it does incremental loading?
Thomas Ahle
@Thomas Ahle: Just pointing you to widgets already created so you can base your code on it.
Macarse
Ah thanks, I misunderstood you.However, it seams like WebImageView uses BitmapFactory.decodeResourceStream internally as well.
Thomas Ahle