title: UICollectionview Scrolling choppy when loading cells
body: <p>I have a gallery in my app utilizing a <code>UICollectionView</code>. The cells are approximately 70,70 size. I am using <code>ALAssets</code> from the <code>ALAssetLibrary</code> in the gallery which I have stored in a list. </p>
  
  <p>I am using the usual pattern for populating the cells:</p>
  
  <pre><code>-(UICollectionViewCell*)collectionView:(UICollectionView *)collectionView cellForItemAtIndexPath:(NSIndexPath *)indexPath
  {
  
    mycell = [collectionView dequeueReusableCellWithReuseIdentifier:cellIdentifier forIndexPath:indexPath];
    mycell.imageView.image = [[UIImage imageWithCGImage:[alassetList objectAtIndex:indexpath.row] thumbnail]];
    return mycell;
  }
  </code></pre>
  
  <p>My gallery is scrolling choppy. I don't understand why this is. I've tried adding a NSCache to cache the thumbnail images (thinking maybe creating the images was expensive) but this did not help for the performance.</p>
  
  <p>I would expect the UI to be as buttery as the stock app.</p>
  
  <p>I am now suspecting it may be something in the <code>UICollectionViewCell prepareForReuse</code> that may be holding up the <code>dequeueReusableCellWithReuseIdentifier</code> method but using instruments I was not able to find this.</p>
  
  <p>Any other thing that may be be causing this? Is there a "faster" way to prepare the <code>UICollectionViewCell</code> or to <code>dequeue</code> them in a faster fashion?</p>