Ideaspike -> winimages
         Previous <—> Next                  HomeSitemapIndex

14.0 - WinImages

14.1 - Magnifying Glass Tutorial

I was wandering around on digg.com and I saw a tutorial on how to make a "magnifying glass" using Photoshop. I thought that was an interesting idea, so I took a look at the actual tutorial.

It didn't look right. After staring at it for about a second, I realized that there was no distortion from the lens. Mmmph. This seemed like a job for WinImages!

So I whipped it up:

The master image (the result of the layered image) is on top. Below and to the left, you can see the warp layer with the magnifying warp in place. At the bottom, left to right, are three shrunken windows that contain the magnifying glass, base image and drop shadow layers. Because the magnifying effect is actually a layer effect, you can move the magnifying glass around (by re-positioning the warp layer using the cursor keys) and the glass, complete with shadow and live magnification of the image material beneath it, will move around over the base image without any further effort on your part. You can also replace the base layer with another image and the magnifying glass will work on that, too. And of course, you could do a "flat magnify" the way the original tutorial did, but that wouldn't look very realistic, would it?

Basically, I took the magnifying glass image from the tutorial, made everything but the frame of the magnifying glass transparent using WinImages "Make Alpha" operator, popped the magnifying glass into a layer above an image (any image will do, of course) and then created a warp layer which I moved in between the magnifying glass layer and the image on the bottom layer.

Then I used WinImages "Dome" operator set to 150 with the Elliptical area selection on the magnifying glass's lens region, and then used "Undo". What this does is creates a lens effect of the precise size and position we want to fit in the magnifying glass. Once the operator has run, using undo removes the static pixel distortion from the magnifying glass layer, because we don't actually want that. We want to create a live distortion using a warp layer. The trick here is WinImages now knows where, and how large, to create the area selection. So...

...now we select "Redo", and click once on the warp layer. This time, the Dome effect creates a live warp in the warp layer, in exactly the same place as we ran the Dome on the magnifying glass layer (this "undo here/redo there" trick is super useful once you get used to the idea) Bingo — now the magnifying glass actually magnifies! The Dome effect, instead of being applied as a pixel distortion, is now embedded in the warp layer as a live distortion that can be re-positioned and otherwise manipulated separately from the rest of the layered image.

Now we want to set the magnifying glass image to "lockstep" in the layers dialog so that the layer with the magnifying glass will follow the layer with the warp in it when we move the warp. This allows the pair of layers to act as a movable object, so you can pan it around over whatever image you have in the layer below it. How cool is that?

Only one more thing to do. Looking at the original tutorial, you can see they've added a drop shadow, so let's do that here as well. Open the layers dialog, select the magnifying glass image, click the "Shadow" button and then "OK", set the shadow layer opacity to 50% (because the default shadow is pretty dark) and that takes care of that. You'll notice that the shadow layer inherits the "lockstep" setting from the magnifying glass layer. Handy!

In order to move the magnifying glass all over the image, click on the warp layer's title bar and tap the cursor keys. You can use shift and control to get larger movements. The three large images at the bottom of the page demonstrate the magnifying glass in three different positions. See how everything moves appropriately?

As it stands now, there is an "issue" here; the warp layer is lowest, so that the warp only affects the base image. On top of that is the shadow, and then the image of the magnifying glass. Technically, this isn't quite right. The shadow should be below the warp. You can accomplish this very easily by moving the shadow layer down by one, turning on "lockstep" for the warp and off for the shadow. Now the whole assembly moves when you move the shadow, instead of the warp. Technically, this is exactly correct and looks just like it should. I've included a clip of the glass region at the bottom of the page that shows how it looks with the shadow on the bottom.

However, if you do this, you lose the view of the shadow at the top left of the inside of the magnifying glass, because it is refracted out of view by the warp layer (as it should be.) I tried this, and I really prefer being able to see the drop shadow, so I put it back the original way. How you do it is up to you. Works fine either way!

This is a good example why I prefer to use WinImages for my day to day work instead of Photoshop. :)

You can download a copy of my layered image here. This image requires WinImages R7 to view or work with. Photoshop can't deal with more than 20 some layer modes and WinImages has about 70. The good news is that WinImages can be had for about fifty bucks.

This last image shows the result when the shadow layer is at the bottom of the magnifying glass layer stack. Technically, it is more correct — the shadow should be missing at the top inside boundary because it is refracted out of view. But I don't like it as much. There's a little more visual drama to the visible shadow.

Have a comment for me? Click here.

         Previous <—> Next                  HomeSitemapIndex