Morphing


Let's talk about morphingthat's right, that craze of the early '90s. Trivia question: What now major studio raised its profile by pulling off the morphing effects in Michael Jackson's "Black or White" video? Hint: It raised its profile quite a bit further a decade later with Shrek.

Thing is, morphing could conceivably come in handy, without being so blatant and obvious. Think of it as a concealing tool, useful when you don't want anyone to notice a transition between two objects or even a transition between one object and itself at a different point in time. Or heck, go crazy morphing together members of your extended family to see if you look anything like the result.

What exactly is a morph? It is, quite simply, a combination of two warps and a dissolve. Given two images, each with a corresponding shape (say, the features of the face), you warp the source image's face shape to the face shape of the target, warp the target from something that matches the source to its face shape, fading the target in over the source.

After Effects has no tool called Morph, and for a long time, the program offered no good way to pull off this effect. In After Effects Professional, you now can use Reshape, a tool that lays the groundwork for simple morphs. You can then build these up into more complex morphs, with separate individual transitions occurring within the overall transition.

Using Reshape to Morph

Unfortunately, creating a morph with Reshape is nowhere near a one-button process, and the simple formula I just mentioned will not provide enough detail for you to be successful. This book generally steers away from step-by-step recipes in favor of helping you solve larger problems creatively, but in this case, it's easy to get confused. Let me walk you through the creation process, using a demonstration of my own resemblance transitioning to that of my evil twin (Figure 7.15):

1.

Start with two elements that have some basic similarities in their relative position of features. The subtler the distortion required, the more you can get away with.

2.

Isolate the two elements you will be morphing from their backgrounds to prevent contamination. If you're working with elements shot against a blue screen, key them out first. Otherwise, mask them. In my example, I have created masks for each layer.

3.

Ascertain that the two layers are the same size in the X and Y dimensions and as closely aligned as possible. If they are not, pre-compose one layer to match the other. This step is important because it will make matching the source and target masks much, much simpler. Name the two layers Source and Target (as they are in the example) if it helps you follow along.

4.

Choose matching sections from your two clips for the duration of your transition (say, 24 frames). If you have still elements, no worries. The closer your moving elements are to still, the more likely you'll get a clean result.

5.

Draw a mask around the boundary that is going to morph in both layers. Be as precise as possible, erring to the inside if at all (Figure 7.16). This could be the masks created in step 2, if you created masks there. It does not have to be active; if you don't need it to mask out the background, you can set it to None. Rename each mask something descriptive like outer (the name used in my example).

Figure 7.16. The outline of each head has been carefully masked. These two masks do not have to correspond to one another; they are defining the boundary for the Reshape effect. You don't want to pull bits of background into your morph.


6.

Create a mask around the area of the Source layer that is the focus of the morph. In my example, it is the facial features: the eyes, nose, and mouth (Figure 7.17). Make this mask as simple as you can; use RotoBeziers and as few points as will work to outline the features inquestion.

Figure 7.17. The full setup along with the look of the top layer at frame one, with visibility turned on. It actually begins the animation at 0% opacity, reaching 100% at the end when it looks like its normal self again.


7.

Set the mask mode to None; this mask is your first shape, you don't need it to influence the layer at all; you will use it for the Reshape effect only. Give it a name (mine is called "me").

8.

Copy this mask shape and paste it in the Target layer. If the two layers are the same dimensions, it should be an identical size and position as it was in the Source layer. The name does not copy with the mask, so you can restore the name (me).

9.

Duplicate the mask. Give it a different color and rename it. In my case, I called the mask "it."

10.

First scale and rotate, then if necessary move individual points (as little as possible!) so that the it mask surrounds the equivalent area of the Target layer that me does of the source: in my example, the eyes, nose, and mouth.

11.

Copy the resulting it mask shape, and paste it to the Source layer to create a new, third mask. Restore the name "it" for this mask. (Don't ask me why names don't copy with masksperhaps someone should report it as a bug.)

12.

You now have three masks for each of the Source and Target layers. Now apply the Reshape effect to each layer.

13.

Starting with the Source layer, set the Source Mask (me), the Destination Mask (it), and the Boundary Mask (outer). Set Elasticity to Liquid (you can experiment with other settings later if need be). Set Interpolation to Smooth.

14.

At the first frame of the morph transition, still in Source, set a keyframe for Percent (at the default, 0.0%, meaning no reshaping is occurring). At the last frame, set Percent to, you guessed it, 100.0%. Now sit back and wait for the gruesome transformation. Don't worry about how it looks yet.

15.

Repeat steps 12 and 13 for the Target layer, with the following changes: Set Source Mask to it and Destination Mask to me. The Percent keyframes should be set to 0.0 at the last frame of the transition (where it is keyframed to 100.0 on the Source layer) and, you guessed it, 100.0 at the first frame.

If at any point during setup it becomes difficult to interact with the UI because After Effects is taking so long updating a frame, enable Caps Lock on your keyboard to prevent any further frame rendering until you're done.


16.

You've created the warps, now you just need the cross dissolve. Set an Opacity keyframe for Target at the last frame of the transition (leaving it at the default 100.0%), and then add a 0.0% Opacity keyframe at the first frame.

Figure 7.15. This is me and my doppelgänger, and that awkward phase in which Jekyll turns into Hyde.


You should now be ready to preview. The preview may take a long time to build the first frame; subsequent frames write much more quickly, so be patient. The main question you must now resolve is whether the features lined up properly; if not, you must adjust the source and destination mask shapes accordingly. I'm sorry I can't be more specific, but for example, if the eyes are too low to match the target halfway through the animation, then dragging the destination mask (it in my example) upward a few pixels in the Composition window, for both layers, should help.

At this point my example is looking good in terms of the face transition (Figure 7.17), but, of course, I've made life hard on myself by transitioning from a head of one size to a larger one, and the edges just kind of fade in. Thereforeand this is where it can get really complicatedI add a second morph, using the same steps as before, but all new masks.

The Correspondence Points property in Reshape can be raised from its default of 1 to make the distortion more precise (and in some cases less twisted). That's cool, but the downside is that it makes this slow effect even slower. Better to try to simplify what you're attempting to do with your masks and fix things there, and try raising this value only as a last resort.


Why complicated? Why new masks? These two questions are interrelated. If you set a second Reshape effect, the key is that you don't want it to influence the result of the first Reshape effect whatsoever. Therefore, this time your Boundary mask is going to be the boundary of the object minus the area covered by the original source and destination masks (it and me). Likewise, my new shapes cover the ears and top of the head, but avoid the area of the previous masks completely (Figure 7.18).

Figure 7.18. The full setup to do more than one morph on a single image is pretty gnarly. Renaming masks and effects to specify which is which, with individual colors and judicious use of mask locks and the Caps Lock key, can help a lot.


Because I know this is complicated, I've included the source project and the final result as projects on the book's CD-ROM. Please do me a favor and don't show the results to my mom. Now a quick look at something I left out (by having you duplicate the Source and Destination masks rather than draw them from scratch).

First Vertex

The Reshape tool relies on a concept that was touched upon already, but is now very significant: that of the First Vertex that exists on every mask. Look closely at any mask you draw, and you will see that one vertex on the mask is larger than all the others. This is the First Vertex.

Reshape relies on the First Vertex to determine which point on the source mask corresponds to which on the destination mask. I had you duplicate the source mask to create the destination mask, because this is the easiest way to satisfy two criteria that are essential for a smooth Reshape effect:

  • Placement of the First Vertex corresponds on both masks

  • Each mask has the same number of points

If either of these criteria is not fulfilled, Reshape will do some not very pretty things to try and compensate. I mention this just in case you try to customize your own mask transitions and don't like what you see. The easiest approach will always be to duplicate the source mask and edit it, keeping the same number of points. The next easiest method would be to draw a new mask with the same number of points, drawn in the same direction (clockwise or counterclockwise), and set to the First Vertex where you need it (by context-clicking on the mask and choosing Select First Vertex from the menu).

Worrying about this stuff is not fun, which is why I avoided the need to do so in the previous section.



Adobe After Effects 6. 5 Studio Techniques
Adobe After Effects 6.5 Studio Techniques
ISBN: 0321316207
EAN: 2147483647
Year: 2006
Pages: 156

flylib.com © 2008-2017.
If you may any questions please contact us: flylib@qtcs.net