05.01.2013 Views

Mac OS X Leopard - ARCAism

Mac OS X Leopard - ARCAism

Mac OS X Leopard - ARCAism

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

474<br />

CHAPTER 25 MAC <strong>OS</strong> X DEVELOPMENT: THE TOOLS<br />

car would then play back your drive exactly as it occurred. The mechanic could rewind and fast<br />

forward, or even pause and disassemble parts of the car frozen in time at the exact moment of<br />

the problem.<br />

Once the problem is diagnosed and fixed, it could be played back to confirm that the problem<br />

no longer occurs. This is exactly what Instruments does for your applications. Whether<br />

you’re the programmer who wrote the application, or a user who finds a bug in it, Instruments<br />

is very exciting.<br />

Under the hood, Instruments runs on DTrace, an OpenSolaris project included in <strong>Leopard</strong><br />

that provides probes in the very lowest levels of the machine. Thousands of these probes sit idle,<br />

causing no performance drain, waiting for the moment they are activated by masters of the<br />

arcane arts wishing to see the details of any process.<br />

While using Instruments fortunately doesn’t require grimoires, sacrifices, or learning the D<br />

scripting language, this open source engine means that the aforementioned arcane masters can<br />

create new instruments and share them with the community. As a further testament to the power<br />

of Instruments, several developer tools in Apple’s toolbox have been replaced with Instruments<br />

templates.<br />

Quartz Composer<br />

Another tool that seems to have been designed by musicians, Quartz Composer is a visual environment<br />

for creating code-free graphical programs using a patch metaphor that should be most<br />

familiar to aficionados of the electric guitar. Instead of functions, Quartz Composer uses modules<br />

called patches. Patches take one or more inputs, change them in some way, and produce one<br />

or more outputs.<br />

Patches are connected by dragging and dropping virtual cables, not unlike Interface Builder.<br />

By connecting the different inputs and outputs, users can create complex compositions, as shown<br />

in Figure 25-22. Quartz Composer compositions can be rolled into freestanding programs, used<br />

as screen savers, or incorporated into other, larger programs. It’s also just a fun way to spend an<br />

afternoon.<br />

Figure 25-22. Visual programming in Quartz Composer

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!