Download image asynchronously

后端 未结 8 824
滥情空心
滥情空心 2020-12-03 19:46

I need to download an image from the web and display it in an ImageView. Presently I am using SDWebImage (It is an asynchronous image downloader wi

相关标签:
8条回答
  • 2020-12-03 20:40

    Yes. You can user other libary. I've already implemented that using AsyncImageView which is inherited from UIImageView. What it does is it stores images in Cache memory fetched from a url and whenever you need to load image from the same URL again it will simply load it from the cache memory saving a lot of time.

    Just follow the link for implementing that:

    https://github.com/nicklockwood/AsyncImageView#readme

    http://www.markj.net/iphone-asynchronous-table-image/

    Please have a look at the image showing the technique I've implemented. It lets you do other activity while images are loading.:

    enter image description here

    0 讨论(0)
  • 2020-12-03 20:40

    Check out EGOImageLoading by enormego for caching images. It Works just like UIImageView and lets you download images from HTTP asynchronously and also its easy to integrate

    0 讨论(0)
提交回复
热议问题