New clear Objective-C

I have come here to chew bubblegum and write code ... and I'm all out of bubblegum.

Saturday, June 28, 2008

Didn't order the special

Wednesday, June 11, 2008

An annoyance with properties

I can:

CGFloat x=someLayer.bounds.origin.x;

But I can't:

someLayer.bounds.origin.x=x;

Tuesday, June 10, 2008

Cocotron and programming salaries

The Unix Geek has a fun entry on programming salaries for languages, API's and operating systems


Good news for Cocotron developers with Objective-C and Win32 in the top tier! :)

Friday, June 06, 2008

CoreGraphics line rendering performance bug

In general CoreGraphics is brutally fast, but I've been noticing some situations where it isn't which I narrowed down to non-uniform scaling of the CTM.

This program demonstrates how non-uniform scaling the CTM can adversely affect line rendering performance. It draws a grid of lines with scaling in X and Y adjustable by sliders and a rotate slider to get feedback on how fast it can render.

There's no voodoo here, the bottleneck is CGContextDrawPath(), drawing the grid scaled 0.5/0.6, or 0.2/0.5 on my MBP can take half a second, whereas if it is scaled 0.5/0.5 rendering is a couple orders of magnitude faster.

CTMScaleBug.zip

10.5.3