This Tutorial published at http://www.retouchpro.com

Background Blurring to Simulate Shallow Depth of Field
Posted by: bart_hickman on 12-31-1969.

"This tutorial will describe how to blur the background in an image to make it appear as though it was shot with a shallower depth of field than it actually was. We will address the issue of removing the subject from the blurry background so it looks realistic. The technique is especially useful for images shot with small sensor P&S cameras which inherently have large depth of field and have no way of getting shallow DOF. This particular tutorial focuses more on what to extract and how to do the blurring and less on the particular extraction method (which can be the subject of another tutorial)."

This tutorial was written with Photoshop CS2, however the techniques should generalize to Paintshop Pro as well.

We will start with this image:

Then make the background blurry to help the flower stand out more and simulate shallower depth of field.  It is common practice to extract the subject (a flower in this case), put it on a separate layer, then blur the original.  This gives a result like this:

Problem here is you can see the blurry rose edge glowing around the edges of the extracted Rose.  In this tutorial I will show a method I use to avoid this problem and get a result like this:

For a bit of added complexity, I also blurred the leaves under the rose just slightly so the result has more depth to it.

Start by making three layer copies of the original as shown here:

Next, we will do the extractions.  You could use any of several extraction methods including: background eraser, image-based-masking, extract filter, magnetic lasso, magnetic pen tool, et al.  I decided the objects were sharp enough and simple enough in this example that the magnetic freeform pen tool would be the quickest--it only took a few minutes.  I configured the pen tool for minimum curve fit (0.5px) and max frequency (100)--this results in the curve fitting the object contours very tightly.

First, trace out the rose:

Next, trace out the leaves under the rose. 

To save time I didn't bother retracing the boundary between the leaves and rose--we'll see later that it's not necessary. 

Whenever using the pen tool like this, I always make sure to make a copy of each path by going to the path palette and dragging the working path onto the "create new path" button to save a copy so I don't lose it.  Here's how the path palette will look after drawing the two paths with the pen tool:

The reason I use the pen tool instead of just the standard lasso tools is I could fine tune the paths if needed.  I didn't have to in this case, but in general you might have to. 

Next step is to move the paths into the channel palette.  Simply ctrl-click the paths in the path palette, then go to the channel palette and click the "save selection as channel" button.  After doing this, the channel palette will look like this:

Now ctrl-click "Alpha 1" to convert it back into a selection, then select the "Rose" layer in the layer palette and click the "add layer mask" button:

So we have our extracted Rose.

Now we'll create the blurry background.  Go back to the channel palette and ctrl-click "Alpha 1", then select "Blurry Background" in the layer palette, and hit the delete key:

Return to the channel palette and ctrl-click "Alpha 2", select "Blurry Background" in the layer palette again and hit delete:

Now apply a Gaussian blur as desired:

Here's how the extracted rose looks superimposed on the blurry background:

We need to increase the opacity of the background so it extends under the rose.  To do this, make several copies of it using ctrl-j.  13 copies seemed to be plenty:

Clean up by merging all the copies.  I renamed the merged layer back to "Blurry Background".

The next step is the leaves.  Go back to the channel palette and ctrl click "Alpha 2".  Then hit ctrl-shift-I (which inverts the selection), then select the "Leaves" layer in the layer palette and hit delete.  This deletes all but the leaves and some of the rose.  To remove the rest of the rose, ctrl-click "Alpha 1" in the channel palette (don't invert it), then return to the "Leaves" layer and hit the delete key.  Now the "Leaves" layer only contains the leaves:

Apply a weaker gaussian blur to the leaves so they appear a bit closer to the camera, but still somewhat in the background:

Merge this with the Blurry background layer:

Again, super-imposing the extracted rose looks like this:

And again, we make a bunch of copies of the "Leaves + Blurry BG" layer to increase the opacity.  This gives us our finished result:

Clean up by merging all of the background copies and you're done!


This Tutorial published at http://www.retouchpro.com