07.12.2012 Views

Adobe Director Basics

Adobe Director Basics

Adobe Director Basics

SHOW MORE
SHOW LESS

Create successful ePaper yourself

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

ADOBE DIRECTOR BASICS<br />

3D: Controlling appearance<br />

Dynamic overlays and backdrops<br />

You can create overlays and backdrops that display animated 2D images. All you need to do is to update the texture<br />

that is displayed by the overlay or backdrop, and its image will update automatically. You can see an example of this<br />

with editable text in “Text in overlays and backdrops” on page 116.<br />

Rotating overlays and backdrops<br />

The built-in rotation feature is fine if you simply want to place a static overlay or backdrop at a particular angle. For<br />

dynamic rotation, you may need a different solution. To simulate the needle on a speedometer, for example, you may<br />

need to rotate the overlay or backdrop around its regPoint. The solution is to roll your own rotation code.<br />

To see an example script, download the movie RotateOverlay.dir. This includes a Movie Script with a handler named<br />

OverlaySetRotation(). You can use this handler to rotate an overlay around its regPoint.<br />

A call to OverlaySetRotation() rotates an overlay about its regPoint<br />

Drag the slider button to rotate the overlay. The regPoint of the blue overlay is set to the regPoint of the Needle<br />

vectorShape member. If you change the regPoint of the member and relaunch the movie, the overlay rotates around<br />

its new regPoint.<br />

Text in overlays and backdrops<br />

For most of your text requirements, <strong>Director</strong>'s 2D text and field members provide everything you need. Sometimes,<br />

however, you may need to display 2D in a 3D environment. To do so, you can use overlays and backdrops. Overlays<br />

and backdrops display textures. You can set the member of a texture to any cast member that has an image property,<br />

including Text members. To make the text look crisp when it is used in a texture, ensure that the rect of the Text<br />

member has dimensions which are a power of 2.<br />

The following example sets the rect of the Text member "Text" to rect(0, 0, 128, 256):<br />

Last updated 8/26/2011<br />

116

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

Saved successfully!

Ooh no, something went wrong!