UICollectionView scrolling is slow

后端 未结 3 1776
北恋
北恋 2020-12-25 08:43

I have just created a UICollectionView in which The user can add images from their phone to the photo album feature in the app. I have the images save to the a

3条回答
  •  Happy的楠姐
    2020-12-25 09:18

    So After some messing around, I've figured out that the problem was based on a few factors.

    One- The images for the thumbnails were too big, so what I did was made a seperate array of images with smaller image sizes that would fit the cell. Two- With the help from @ggrana, opening a seperate thread sped up the process to and made it less laggy. Three- I also found that having an array of images rather than image locations was faster-- only problem is it takes up more memory.

提交回复
热议问题