Once your subject is isolated and you have filled the transparent hole it left behind, you can try your hand at being a digital puppeteer. Turn on the visibility of the new layer you created in Tip #81; the image should look as it did when you started. Choose Edit > Puppet Warp. This is also a new feature in Photoshop CS5. A special grid will display over your layer and provide several settings in the Options bar (Figure 83a).
Figure 83a The Puppet Warp options.
There are three different types of warping that Photoshop can apply: Rigid, Normal, and Distort. These refer to the amount of elasticity applied to your subject when warping. Generally, Normal will strike a good balance between texture quality and warp flexibility.
Density refers to the number of triangles that make up the grid or mesh that covers your warp subject. The higher the density, the smoother the results of the warp but the longer the processing time. Generally, the Normal density works well.
This setting expands or contracts the outer edge of the grid or mesh.
Pins and Pin Depth
Pins are the small markers along your warp layer that Photoshop uses to warp the image when you click and drag them.
Pins— This method allows you to push, pull, bend, or rotate part of the mesh, and therefore the layer that is attached to the mesh. To add a pin, click the spot on the mesh where you want the pin to be located. When you select a pin, it displays a black dot in the middle; a selected pin is also known as the active pin, .
To move part of the mesh, click a pin and drag. To rotate the mesh instead of dragging it, select the pin and press and hold the Alt key. A small circle will appear around the pin; drag it to rotate. Figure 83b shows several pins attached to the mesh, with the active pin being rotated. To delete a pin, right-click it and choose Delete Pin from the context menu. To delete all pins and start over, click the Remove All Pins button on the Options Bar, .
Figure 83b The ability to manipulate pins allows you to generate the warped layer mesh.
Pin Depth—This setting is useful when you wrap part of the grid or mesh over on itself (overlap areas controlled by other pins), and need to reveal a portion of the mesh that is hidden from view. As you click the Set Pin Forward (Left) and Set Pin Backward (Right) buttons, , different areas of the overlapping mesh will be "pulled to the top."
Essentially, the overlapping areas are treated like stacked layers. Clicking the Set Pin Forward and Set Pin Backward buttons reveals different parts of the "stack." The trick is to remember that you are not changing the order of the pins; rather, you're changing which part of the overlapping meshes are "attached" to the active pin and therefore, which part of the mesh will move when you move that pin (Figure 83c).
Figure 83c Use the Set Pin Forward and Set Pin Backward buttons to change which portion of an overlapping mesh is attached to the active pin.
This setting determines whether a pin will be automatically rotated based on the warp mode and other settings (Auto), or whether it will rotate a fixed number of degrees (Fixed). Generally, leaving this to Auto works well. If you want to use Fixed, choose it from the Rotate pop-up menu and in the text field to the right, type in the number of degrees.
The Finished Warp
Figure 83d shows the final warp arrangement with all mesh settings and pins visible; Figure 83e shows the final image with warps applied.
Figure 83d Very complex warps can be set up using the Normal Mode and Mesh Density.
Figure 83e The final warped flag.