1

I'm trying to replicate the functionality of Facebook's image upload. To briefly describe it you click the Photo button from the main screen of the app you are taken to an image picker that will let you select up to 30 images. Once selected the images load in some kind of list view that allows you to add a caption, remove the image from the list, or do some other Facebook-y things. If you scroll around the list can move very quickly, and if you only have 5-10 images you generally spend little to no time waiting for items to reload.

Right now I have a recycler view and am using Picasso to load the images from disk, resize them, and then display them. This works, but it's not smooth or fast. Even if I only have five or six images loaded they don't come up instantly if I scroll from the bottom back to the top. I have tried increasing the LRU Cache size in Picasso, but that didn't do anything at all. It seems like the scaled image isn't getting cached so it has to be scaled to fit the screen width every time. That's just my guess though.

Any suggestions on how to get this to run more smoothly?

Jason
  • 165
  • 1
  • 1
  • 6
  • 1
    this may help https://stackoverflow.com/questions/26856487/recyclerview-painfully-slow-to-load-cached-images-form-picasso – Rashim Catalan Dhaubanjar Nov 25 '15 at 00:48
  • I had read through that page before posting this and didn't really see anything that could help. The top response seems geared for loading images from the network, which I'm not doing, and I would like to avoid additional libraries if I can. The info about Picasso didn't really help. I am using the images at the size I change them to, and I did increase the cache size, didn't work. The last comment is almost nonsensical, as it would lead to reusing the wrong image instead of loading the correct one. – Jason Nov 25 '15 at 00:57

0 Answers0