My android application has to show thumbnails of the audio file album art for each and every song. The mobile i'm testing on has about 2000 songs, so, I need to optimize the performance. There is a lot of lag if I use adapter's getview to load thumbnails.
So, to make it asynchronous
I've added thread
to load images, but it turns out 2000 threads are created to load all 2000 thumbnails.
Is there a way to optimize this? like lazy loading or live scrolling in android?
Update: Also, I'd like to get rid of the image thumb nails from the memory when scrolling as the number of images can cause OutOfMemory error.
Thanks.
This is lib u can use for lazy loading : Lib
Will optimize ur thumbnail performance.
Scroll listview smoothly
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.