NHS Designs

advanced compositing 17

Graphic Design Tutorials

Layer Masks - Advanced Compositing

Layer masks aren't just for collaging and blending photos. They're actually a very powerful selection and design tool.

We'll work on a Web site design with a lot of visual impact. You will use the shape of one layer to create the mask for another. We'll create the illusion that the skier is breaking right out of an LCD screen.

  1. Open three images: skier.jpg, monitor.jpg and mountains.jpg.

advanced compositing 1

  1. Start with the photo of the skier.
  2. Open the Color Range command: Select > Color Range.
    1. In the Color Range dialog, make sure that the preview is set to Selection.
    2. Click on the photo near the top part of the sky.
    3. Press the Shift key and click on other areas of the sky until the entire sky area is white in the preview.
    4. Set the Fuzziness slide to 160.
    5. Click OK.

advanced compositing 2

  1. Now the sky is selected. We want the skier selected, so go to Select > Inverse.
  2. Press Ctrl+J to copy the skier by herself to a new layer.
  3. Save this file as skier.psd.

advanced compositing 3

  1. Time to move both of the layers over to the LCD screen. Click on one of the layers in skier.psd, then hold Ctrl down and click on the other layer.
  2. Drag these layers over into monitor.jpg. Aim for inside the LCD screen.

advanced compositing 4

advanced compositing 5

  1. Save this file as web-mockup.psd.
  2. Click on the eye icons in front of the two skier layers to hide them, so we can see the LCD again.
  3. Select the Polygonal Lasso tool from the Toolbox, and make a rectangular selection of the LCD screen.

advanced compositing 6

  1. Unhide the skier layers (don't deselect yet.)
  2. Click on the bottom skier layer (the one with the enitre photo on it) and click on the Add Layer Mask icon at the bottom of the Layers palette. Photoshop automatically hides everything on this layer that extends past the rectangular selection you drew.

advanced compositing 7

  1. Now we want to apply the same layer mask to the top skier layer. But we don't have to draw our selection agin. Press-and-hold the Alt key, then click-and-drag the layer mask from one skier layer to another.

advanced compositing 8

  1. Save the file.
  2. We have a layer mask on Layer 2 (the top skier image) but right now we really need to see just the image again while leaving the layer mask in place. We want to position her skis so they break out past the screen bottom, and her head so it breaks out of the top edge:
    1. Hold Shift down and click on the Layer Mask thumbnail for Layer 2 to temporarily diable the mask.
    2. Before we move the layer, click on the little link icon that appears between the layer thumbnail and the layer mask thumbnail to unlink them. Do the same for Layer 1 below it. This allows us to move the images while keeping the screen outline in place.
    3. Make sure Layer 1 is still selected. Ctrl-click on the words "Layer 2" to select both at the same time.
    4. Use the move tool to reposition the skier image so her head and skis pop out of the screen.

advanced compositing 9

    1. Relink the layer masks to the layers.
    2. Click on Layer 2's layer mask thumbnail to turn it back on.
  1. Now take a look at the layer thumbnail for Layer 2. We need to change the layer mask so the her head and skis are visible. This will require painting white on the mask:
  1. Select the Brush tool.
  2. Set the Foreground color to white.
  3. Make sure that Layer 2's layer mask is still selected.
  4. Paint aroung the skier's head until is is all revealed.
  5. Paint around the ski tips until they are revealed along with some snow spray.
  6. Paint back some snow spray of the right side of the screen.

advanced compositing 10

  1. The snow that's bursting out of the screen has some blue outlines because it was selected from a blue sky. Let's fix it:
    1. Zoom in to the snow spray.
    2. Select the Dodge tool (the one that looks like a sucker) from the Tool box.
    3. In the Options bar, set Range to Midtones and Exposure to 50%.
    4. Click on the layer thumbnail (not the layer mask) for Layer 2.
    5. Paint the snow spray with the Dodge tool.
    6. Stay away from the image inside the LCD screen.

advanced compositing 11

  1. Save the file.
  2. Bring mountains.jpg up front.
  3. Select the Rectangular Marquee tool and make a large selection which spans across the horizon and includes some sky and tree tops.
  4. To get rounded corners, go to Select > Modify > Smooth. Enter 20 pixels for the Sample Radius, and click OK.

advanced compositing 12

  1. Select the Move tool and move this selection into web-mockup.psd. Position it near the top of the overall image but leave some room around it.

advanced compositing 13

  1. Move the new layer, Layer 3, down beloew the two skier layers in the stack.
  2. With Layer 3 still selected, add a white stroke around it:
    1. Edit > Stroke.
    2. Change the Width to 2 and the color to white, then click OK.

advanced compositing 14

  1. There's still a bit of the monitor frame being hidden behind the mountains. Let's fix that:
    1. Hide the mountains layer (Layer 3) so we can see the monitor corner.
    2. Select the Polygonal Lasso tool.
    3. Make a selection around the outside edges of the monitor (you don't need to include the stand.)

advanced compositing 15

  1. Inverse the selection (Select > Inverse).
  2. Turn the mountains layer back on and make sure it is still selected.
  3. Click the Add Layer Mask icon at the bottom of the Layers palette.

advanced compositing 16

  1. Save the file.

This would be a great beginning to a Web mockup, ready for client review. Here I've added some navigation:

advanced compositing 17


Thanks to Layers by Matt Kloskowski for these tutorial ideas.

resources · copyright information · Natomas High School Design Department