I am planning to implement a component similar to the iphone's photo album.. I guess that using uviews will make the component to have a bad performace , I mean scrolling slow and all of the stuff ... so which way should I take? Is CALayer better than UIViews in terms of performance? Is there any other (lighter) way to draw images or text without using UIView subclasses?
Any link or idea will be great,
Thanks you!
There are plenty of tutorials about graphics and the pros and cons of UIView vs drawing. I'm no expert but I suspect that performance is more likely to come from your instantiation and caching strategies. I.e. if you want fast scrolling then looking at minimising the number of objects instantiated, caching and reusing those that are and an effective block loading routine for loading data will all yield large benefits.
But I'd be inclined to do a simple proof of concept app first, load it onto a device and see how fast it goes and where you are most likely to need to address performance issues. Apart from standard design strategies such as caching and reusing components, attempting to optimize the performance before you have identified where the performance bottlenecks are occurring is generally not a good idea.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With