Using Puppet Warp
Much as we wish all the images we work with were perfectly composed, occasionally things are just out of place and need to be moved. It could be something as small as an eyebrow or as massive as a skyscraper. Whether you need to change a facial expression or rearrange a city skyline, consider using Puppet Warp. It gives you the ability to move, stretch, and twist specific parts of an image by placing and dragging pins connected by a visual mesh. When used to maximum advantage, it’s like having superpowers to reach into a photo and resculpt elements as if they were made out of clay.
While Puppet Warp can be used to create amazing special effects, you’ll generally need to stick to subtle, small changes if you want to keep things looking realistic.
Puppet Warp works best on subjects that have been isolated on their own layer. Use Content-Aware Fill to fill in holes in the background, if necessary. Areas separated by transparency on the layer will have independent meshes.
To manipulate an image with Puppet Warp:
On the Layers panel, select the layer you want to manipulate.
Choose Edit > Puppet Warp.
Set pins in the image by clicking where you want to pull or rotate elements, as well as where you want to lock other elements in place (FIGURE 15.17).
FIGURE 15.17 Here, we’ve placed eight pins. One on the flamingo’s head so we can move it, and the rest around its body to lock down the rest of the bird.
Drag pins to warp the image (FIGURE 15.18).
FIGURE 15.18 Dragging the pin on the flamingo’s head moves and rotates it. Puppet Warp is so perfectly suited to manipulating flamingos we almost think it should be renamed Flamingo Warp!
To accept the result, Press Enter or click the Commit Transform button (). Or, to cancel and leave the image unchanged, press Esc or click the Cancel Puppet Warp button ().
While a nod may be as good as a wink in some cases, other times you need to refine your warp beyond, for example, our initial head movement. Use the following controls in the Options bar to change the effect of Puppet Warp:
Mode controls the elasticity of the mesh. In most cases, the default Normal works fine. Choose Rigid to minimize pixel stretching and perspective effects, or choose Distort to maximize them (FIGURE 15.19).
FIGURE 15.19 The different results you can get with a pin in the same location, using the Puppet Warp Mode options: Normal, Rigid, and Distort.
Rotate can be set to Auto or Fixed. Leave it on Auto if you want a mesh point to rotate automatically as you drag it. Set it to Fixed if you want to apply a specific rotation angle manually.
Pin Depth determines what happens when parts of the layer you’re distorting overlap each other. Each time you click to set a pin, the new one is set above all others. Click the buttons in the Options bar () to set pins forward or back in the stacking order and change the overlap effect (FIGURE 15.20).
FIGURE 15.20 By changing the depth of the pin on the flamingo’s head, we can make it appear in front of or behind the rest of the bird.
Show Mesh reveals the mesh applied to the layer.
Density controls the spacing between mesh points. More points create a finer mesh and more precise results, at the cost of slower processing. Fewer points give you faster, less precise results.
Expansion controls the overall size of the mesh. It gives you another way to control the spacing between mesh points. Positive values expand the mesh outward. Negative values will contract the mesh, hiding pixels at the edges.