Chapter 5. Transformations

The separation of user space from device space is the source of much of the power of the Quartz 2D graphics library. As we’ve already seen, your application constructs its graphics in the resolution independent graphics environment of user space, but before the computer can reproduce the graphics on a device, it must first move the graphics to device space. Transformations are the tools that the computer uses to move graphics from one coordinate system to another.

Quartz 2D includes a set of tools for creating and combining transformations. Your application can take advantage of these tools and use them to simplify many of your drawings. The general strategy is to select a convenient coordinate system in which to draw ...

Get Quartz 2D Graphics for Mac OS X® Developers now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.