[Drawkit] Is it "Touch" time?
Dick Applebaum
dicklacara at mac.com
Tue Jul 28 06:09:12 PDT 2009
Thanks Graham.
I did a little googling and found that the iPhone does have
UIBezierPath, somewhat equivalent to NSBezierPath. Unfortunately,
this is not (yet?) in the iPhone SDK. It is currently accessible for
JailBroken phones, which limits its utility.
The reason, I mention this at all, is that as the iPhone OS evolves,
iPhone developers see more and more APIs/Frameworks ported (or
exposed) to Cocoa Touch. Several Mac developers on the iPhone
developer forums have commented that Apple appears to be "doing it
right" and re-implementing things as they are ported to the iPhone OSX
(and that these implementations will find their way back into Mac OSX).
I just did a cursory check of the new iPhone SDK 3.1Beta 3 (dropped
today) and didn't see anything relevant :(
Maybe, the situation will improve when Apple introduces the rumored
tablet device... sigh!
Dick
On Jul 27, 2009, at 7:42 PM, Graham Cox wrote:
> The main problem for porting DK to the iPhone, which remains, is
> that the core drawing that DK does is heavily based on NSBezierPath
> rather than the lower level CGPath interfaces. Likewise DK uses
> NSGraphicsContext over CGContext, NSColor over CGColor and NSImage
> over CGImage.
>
> If porting were attempted it would probably make most sense to
> recreate these objects rather than rewrite DK to use the
> CoreGraphics approach directly, simply because of the large amount
> of code that extends and uses NSBezierPath, and while we do not have
> access to the source of these, they are mostly simple wrappers
> around the CG code anyway, so it would be feasible to do, if a
> substantial effort.
>
> I'm unsure why Apple chose to drop these from the iPhone APIs as
> they don't cause a major performance hit and are easier to use than
> the CG counterparts, but that's for them to know and us mortals to
> merely speculate and wonder. If I'd have known that Apple were
> planning to take this direction when I started DK I might have done
> things differently, but they didn't make that decision public until
> the SDK was released as usual.
>
> We could also all file bug reports asking for the iPhone APIs to
> include NSBezierPath and the other higher level graphics APIs. You
> never know...
>
> --Graham
>
>
>
> On 28/07/2009, at 8:47 AM, Dick Applebaum wrote:
>
>> AIR, the response I got from Graham was that the iPhone OS did not
>> contain the necessary APIs/Frameworks to facilitate porting--
>> making the port effort a major rewrite (and distraction).
>>
>> In the interim several things have happened:
>>
>> -- The iPhone Hardware has been improved, specifically CPU, GPU,
>> Compass and Camera
>> -- The iPhone OS has been enriched, incorporating more APIs from
>> Mac OSX and new iPhone APIs and OpenGL ES 2.0
>> -- Apple claims that much of SnowLeopard has been re-implemented in
>> Cocoa
>> -- Evidence is that Snow Leopard is incorporating some APIs and
>> frameworks from the iPhone (they share some amount of a common code
>> base)
>>
>>
>> Now, there are lots of rumors that Apple will soon announce a
>> MultiTouch 10" Tablet device for delivery this year (lots of
>> supplier rumors support this).
>>
>> So, given this:
>>
>> Is it practical, and is it time to port DrawKit to the Touch
>> interface?
>
> _______________________________________________
> Drawkit mailing list
> Drawkit at lists.apptree.net
> http://lists.apptree.net/listinfo.cgi/drawkit-apptree.net
More information about the Drawkit
mailing list