macdevcenter.com
oreilly.comSafari Books Online.Conferences.

advertisement

AddThis Social Bookmark Button

Getting Started with Quartz Composer
Pages: 1, 2, 3

Up the Spiffy Quotient

Sure, flying a picture across a screen is pretty neat, but there's a lot more you can do with Quartz Composer than creating what is essentially a two-dimensional effect. In the following steps, you'll dial it up a notch to create an animated three-dimensional cube.

  1. Return to Quartz Composer. Open your MyFirst.qtz project file. Select the Billboard renderer and delete it. You're about to use a more animated element.

  2. Open the Clip Library. It's on the left side of your screen, in the same location as the patch library. Drag a copy of Rotating Cube onto the editor.
    figure

  3. Make your connections. As you did with the Billboard, connect your image to the Rotating Cube's image input, and the Interpolation result output to the Rotating Cube's X position.
    figure

  4. Examine the Viewer. Viola! Instant spiffy animation. Your cube rotates in from the right and out to the left. It should look pretty good, other than being a bit dark.
    figure

  5. Adjust the ambient lighting. The reason the cube is so dark is that the default ambient light is so low. To fix this, double-click the Rotating Cube renderer. The Editor clears, replaced by a single Lighting renderer. This patch is actually part of the Rotating Cube, but hidden inside it.
    figure

  6. Update the Lighting properties. Select the Lighting renderer and open the inspector. Choose Input Parameters from the Inspector pop-up menu. Click on the Ambient Light color well and use the Color palette to adjust that color to a much lighter shade of gray. Close the Inspector and Color Palette after making your adjustments.
    figure

  7. Return to the top-level editor. Click Edit Parent to go back to your normal editing view.
    figure

  8. Again, check out the Viewer. The cube and the images on it appear brighter this time.
    figure

  9. Save to disk. Save your new, updated Quartz animation to disk as MySecond.qtz.

Pages: 1, 2, 3

Next Pagearrow