3D Photo Effect From A 2D Image
Written by Ken Lowther   
Saturday, 29 December 2007

There are many tutorials available regarding this effect, but I have not seen one showing how this can be done in PhotoImpact.  In this tutorial, we will take the 2D image shown below

Image
2D Image

and create a 3D effect like the one shown in the next image.

Image
3D Effect

If you wish, follow along in the tutorial using an image of your own choosing or you can download the original image used in the tutorial from here.

 

Framing the 3D photo

First we will create the 3D photo frame around the dancing couple.  Assuming that you have opened your image in PhotoImpact, choose the standard selection tool as shown in Figure 1.

Image
Figure 1

Create a static selection by drawing a box around the couple similar to that shown in Figure 2.

Image
Figure 2

Don't worry too much about getting the selection exactly right at this point.  You will be able to adjust it more accurately in the next step.  Switch to the transform tool as shown in Figure 3.

Image
Figure 3

In the attribute toolbar, select the Resize transform (Figure 4).

Image
Figure 4

Also, make sure to click on the 'Action on selection' button in the attribute toolbar (Figure 5).

Image
Figure 5

This forces the resize transform to take action on the current selection.  Your selection should now appear as shown in Figure 6.

Image
Figure 6

At this point you can grab the selection at any of the handles and resize it as needed.  You can also move the entire selection around until you are satisfied with its position.  Again, try to get your selection to appear as close to the one in Figure 6 as possible.  Note: you might have to unlock the 'Keep aspect ratio' button in the attribute toolbar to get the selection to resize height or width independantly of each other (Figure 7).

Image
Figure 7

Now switch to the Perspective transform by going to the attribute toolbar and selecting the Perspective menu item (Figure 8).

Image
Figure 8

Grab the handle in the upper left corner of the selection and move it down until it resembles the one shown in Figure 9.

Image
Figure 9

When you are satisfied, create a new object from the selection by pressing Ctrl+Shift+O or going to the Selection menu and selecting 'Convert to Object'. This should create a new object from your selection.  You can verify this by looking at the Layer Manager.  It should appear much the same as Figure 10.

Image
Figure 10

You can also hide the base image by hitting Ctrl+F5 and see just the newly created object (Figure 11).  Ctrl+F5 again will redisplay the base image.

Image
Figure 11

If you haven't already, now would be a good time to save your work.  Since you originally loaded a JPG image, you'll want to use the 'Save As' function (Figure 12) to accomplish this.

Image
Figure 12

Remember to change the 'Save as type' to UFO (Figure 13) so that your newly created objects are saved intact.

Image
Figure 13

Now that you have your 3D frame created, you can paint the white photo frame around its edges.  Select the paintbrush from the toolbox window (Figure 14).

Image
Figure 14

In the attribute toolbar, set the paint color to white, brush shape to square, brush size to 75 and soften paint edges to 0 (Figure 15).

Image
Figure 15

Now, making sure that your newly created 3D frame object is active as shown in  Figure 10, select the 'Paint on Edges' menu item from the 'Effect' menu (Figure 16) or use the keyboard shortcut SHIFT+P to invoke the same function.

Image
Figure 16

You should now have a white border around the 3D frame object like the one shown in Figure 17.

Image
Figure 17

Before proceeding with the next section, hide the 3D frame object so that it doesn't get in the way.  You can do this by going to the Layer Manager and clicking on the eye icon (Figure 18).

Image
Figure 18

 

Cutting Out the Dancing Couple

This section is the most time intensive portion of the project.  In order to get the dancing couple to 'stand out' in front of the 3D photo frame, you must extract or 'cutout' a copy of them from the original photo.  To do this, you will use the lasso selection tool to trace around the outside edge of the couple.  From the toolbox, select the lasso tool (Figure 19).

Image
Figure 19

Before beginning your selection, it is best if you can arrange the image of the couple to be as large as possible without the need to scroll in either direction to get to any of the edges.  This is because, once you begin the selection, it is difficult scroll the image around without messing up the selection process. The best way that I have found to accomplish this is to use full-screen mode, toggled by keying CTRL+U, and increasing the size of the image (using the + key) until the entire image of the couple is as large as it can be without any of the edges going off screen.  Once you have completed the selection you can go back to normal display mode by keying CTRL+U again.

There a two ways to use the lasso tool.  They are controlled by the 'Smart lasso' checkbox in the attribute panel (Figure 20).

Image
Figure 20

With smart lasso turned on, you start by performing a left click somewhere on the outer edge of the area that you are going to cutout.  This creates an initial anchor point and causes PhotoImpact to display a circle around the current cursor position.  The circle represents the area around the cursor that PhotoImpact looks at to automatically detect the edge of the object.  The size of the circle, the area to consider when tracing, is controlled by the setting in the attribute panel Figure 20.  The larger the value, the larger the circle.  After performing the initial left click, trace the subject by moving the mouse over the edges of the couple (no need to hold down the mouse button).  While tracing, when you have made a desired edge selection, left click on the selection path to add an anchor point (Figure 21).  Adding an anchor point prevents you from accidentally retracing (deleting) your selection path.

Image
Figure 21

If you make a mistake in selecting, just retrace along the selection path to the point where you want to begin selecting again.  You cannot retrace a path that is between two anchor points.  To delete the current selection path that is between the last anchor point and the current cursor position, press BACKSPACE. 

With smart lasso turned off, the selection process is essentially the same except that PhotoImpact will not do automatic edge detection.  In this mode, there is no 'area to consider' circle displayed, rather, your selection is a series of straight lines that you angle to enclose the subject.  Every time you left click, the current selection point is locked down (Figure 21a).  This results in a somewhat blockier selection, but can be done much quicker and in some cases the results are just as good.

Image
Figure 21a

Regardless of whether you use smart lasso or not, once you have made it all the way around the edges of the subject, click on the starting anchor point to close the selection.  The selection path, instead of the usual dotted path, becomes a line path (Figure 22).

Image
Figure 22

Don't worry too much about getting the selection perfect at this point, it can be fine tuned later on as you will see.  Now that you have the selection path defined, click on the 'generate lasso selection' button in the attribute panel (Figure 23) to create a normal selection from the line path (Figure 24).

Image
Figure 23

Image
Figure 24

At this point, you need to fine tune your selection, making it a more precise.  This is not as difficult as it might first appear.  Since, for this project, the cutout will remain in its original position overlaying the 3D photo image, a large portion of it will not need to be fine tuned.  Only the parts that extend outside of the 3D photo frame need to be adjusted (Figure 25).

Image
Figure 25

The remaining areas of the cutout that are inside of the 3D photo frame will not be distinguishable from the underlying photo frame.  They are really only needed to generate the shadow in the final image and can remain 'rough cut'. To do this, you must edit the path by clicking on the 'edit path object' button in the attribute panel (Figure 26).

Image
Figure 26

When you edit path objects, they will be displayed as a wireframe structure (Figure 27).  This structure essentially consists of the line and curve segments that comprise the path.  Each segment contains nodes and up to two control handles at each end, all of which you can adjust by dragging.  Nodes let you control the start or end position of a line segment, whereas control handles let you control the shape of a curve.

Image
Figure 27

Clicking on a particular node activates it and exposes its control handles (Figure 28).  Once activated, you can move the node around by dragging it where you want it.  The adjacent segments will grow/shrink as you move the node around.  You can also change the shape of the paths curve by grabbing a control handle and dragging it. In this case, the node remains stationary, only the shape of the segment changes.

Image
Figure 28

Typically, during normal path editing you will operate in 'Pick Node' mode (Figure 29).  In this mode, to add a node to the path, click on the segment where you want a node added to activate it, then right click and select 'Add Point' from the context menu.  A new node will be added in the middle of the selected segment.  You can also delete a node in the same manner by activating the node then right clicking and selecting 'Delete Point' from the context menu.

Image
Figure 29 - Attribute Panel

To add or delete a lot of nodes from the path, it might be quicker to use the 'Add Node' or 'Delete Node' modes instead (Figure 29).  In the Add Node mode, a new node is added wherever you left click on the path.  In Delete Node mode, any node that you click on will be deleted.  If you use the 'smart lasso' option of the lasso tool to create the path, this can be a real time saver as it tends to create a lot of nodes many of which can be deleted.

Zooming in on the area that you are editing (using the + key) allows you to get a good detailed view of your path and the image you are editing.  As you can see, there are a number of tools available that enable you to create very precise selections.  Path editing may seem a bit cumbersome at first, but it gets easier with a little practice and patience.  It is a skill that is well worth the time to master.

Before beginning your path editing, you might want to save your work so that you have a good restart point.  Having created your rough cut selection, you can now save at any time and resume later if need be.  Path editing can be tedious work and the ability to save and resume later is a lifesaver.  To resume path editing, load your saved project and select the path edit tool (Figure 30).  From the attribute bar, click on the 'Toggle between object and wireframe modes' button (Figure 29) and you are back in business.

Image
Figure 30

Concentrate your editing on the four areas of the selection circled in Figure 25.  For example, you should be able to change the selection in Figure 27 to appear more like that shown in Figure 30a.

Image
Figure 30a

Once you have these fine tuned, examine the remaining areas of the path making sure that there are no really wild variations from the edge of the couple.  Again, these remaining areas are not really that important other than they will affect the shape of the shadow that will be generated in the final image.

When you are satisfied with your selection, create a new object from it by keying CTRL+SHIFT+O or selecting 'Convert to Object' from the Selection menu.  Now you can 'un-hide' the 3D Photo frame from the previous section.  Your layer manager should now appear similar to the one in Figure 31.  Make sure your objects are listed in the Layer Manager in the same order as in Figure 31.  You can rearrange their order by clicking on the object you want to move to activate it and then using ALT+UP or ALT+DOWN shortcut to move the object up or down in the list or you can drag it into position with the mouse.

Image
Figure 31

Your image should now appear much the same as the one in Figure 32.

Click to see actual size
Figure 32

Finishing touches

The most difficult part of the project is out of the way. All that remains are some finishing touches to spruce up the final image. In the Layer Manager, click on the base image to activate it then right click and select 'Duplicate' from the context menu.  This should create a copy of the base image (Figure 33).

Image
Figure 33

Making sure that the duplicated object is active, key CTRL+F or select 'Fill' from the Edit menu. In the Fill dialog box, select the Gradient tab and change the settings to match those in Figure 34 and select OK.

Image
Figure 34

This should fill the duplicated object with a nice white to black gradient as shown in Figure 35.

Click to see actual size
Figure 35

To further enhance the 3D look, add a shadow to the dancing couple by clicking on the object in the layer manager and keying SHIFT+S or right clicking and selecting 'Shadow' from the context menu.  Change the settings in the Shadow dialog box to match those in Figure 36 and select OK.

Image
Figure 36

And finally, add a shadow to the 3D photo frame using the settings shown in Figure 37.

Image
Figure 37

Your finished project should now appear much the same as that in Figure 38.

Image
Figure 38

With that, the conclusion of this tutorial is finally at hand.  Here is another simpler example of how a 3D effect can be applied.

Image
Original Image

Image
3D Effect

As you can see, the possibilities with this technique are endless, limited only by your imagination.  I hope you enjoyed this tutorial and was able to get something useful from it.

Happy editting.

 

Last Updated ( Tuesday, 15 January 2008 )