views:

115

answers:

2

Hi all,

I am trying to draw custom shapes in iPad application. I am using UIBezierPath for drawing which is available for 3.2 onwards. My question is whether it is good to use this class or should I go to the core graphics? Is there any difference between uibezierpath and core graphics drawing related to performance?

+2  A: 

UIBeizerPath is just there to make your life easier. If your app is for iPad and iPhone (i.e. Universal) and coming out post iOS 4 then there's no downside of using the class other than it won't work on the iPhone 2G (which won't be getting iOS 4).

Lee
@lee: Yes I know that this class is available for 3.2 onwards. But my question is regarding the performance. Will it be as faster as core graphics?
Manjunath
It's a helper class - it uses CoreGraphics just like you would - As I said, it's just there to make life easier. Not necessarily faster or slower. Your decision to use should be based on what I said in my answer rather than speed.
Lee
A: 

It should be basically the same speed. The real question: does it do what you want? I've used it when I can (because it's simpler), and used Quartz when I had to.

And as far as speed: don't prematurely optimize. Measure (with Instruments).

David Dunham