Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Performance of image vs custom drawing in UIKit

I have a UITableCell that has a few gradient layers and drop shadows in it. I'm wondering if it would be more performant to handle this with coreanimation layers or just use a a single background image for the cell?

In general is it more performant to use large images (with transparency) over core animation? What's the best way to test the difference? I'm guessing Instruments would be involved. Also I'm looking for a good resource on iOS performance testing and best practices. Sorry for the multiple questions.

like image 449
Christian Schlensker Avatar asked Jul 16 '11 19:07

Christian Schlensker


1 Answers

In my experience, using images is always faster than drawing manually.

like image 70
Erik B Avatar answered Oct 25 '22 19:10

Erik B