Macro Photography – Focus Stacking


In the last tutorial I went through the basics of macro photography using just a basic camera / kit lens combination and a really cheap extension tube.  We saw that the main technical difficulty is the shallow depth of field which becomes a problem at higher magnification levels.  In this tutorial we’ll get past that by using a technique called focus stacking to stack multiple images focused at different points of a subject on top of each other to create a fully focused subject.


In this example I’ve used the following

*links from whatever random sites I could find quickly on google

I would generally try to use as little equipment as possible for this blog but I added the LED ring light, the focusing rail and the shutter release to save myself a bit of time, I did all this late at night so I was in a bit if a rush.  They make things a little easier but are not required for this process to work.

Taking the shots

The goal here is to take a number of picture ideally starting at the point of the subject closest or farthest to the lens and then walking the focus plane away from or toward the lens in small steps.   You need to make sure you have a clean image of each piece of the subject.

This can be done a number of ways:

  • Manually focusing on different parts of the subject
  • Setting the lens to its max magnification setting and moving the subject to change the focus plane
  • Setting the lens to its max magnification setting and moving the lens to change the focus plane.

Initially I’d recommend the first option, the 2nd option can be particularly difficult unless the lens is parallel with the table the subject is on otherwise you may need to raise / drop the subject to get it closer to the lens.  Since I used a focus rail I went with the third option but any of them can work.  i also used mirror lookup and the shutter release to reduce vibration (but on all but the last series I rushed a little too much and didn’t let the camera settle after moving the rail).

I took a number of stacks, some using the Tamron  macro lens and one using the kit lens and tube so show the differences between them.

I’ve posted the individual shots (after adjustments in lightroom) and the stacked results for each lens next to each

Kit Lens Results


This slideshow requires JavaScript.

Stacked Result

Kit Lens Focus Stacking Example

Dedicated Macro Lens Results

I took two series of images with this lens, I also took a shot of the first series at f25 so you can see the difference between a really small aperture and a series of stacked images so you can get an idea of the effort vs reward

Series 1 Images

You can see here I stopped a little early – it would have been better to get one or two more shots to get the furthest part of the flower in clean focus

This slideshow requires JavaScript.


Series 1 Stacked Results

Focus Stacking Example Result

Single shot @ F25

Example shot with small apeture

Series 2 Images

You can the below series has a lot less movement because I slowed down a little and took my time, because of this I didn’t need to crop the resultant stack at all.

This slideshow requires JavaScript.

Series 2 Stacked Results

Focus Stacking Example Result


I processed the shots in lightroom dialing up clarity and tweaking the colours a little then ran them through some stacking software.  There are multiple options, the free ones I have tried are:

  • ImageJ
  • Enfuse
  • Picolay

Of the above options I find Picolay the easiest to use, simply add the images, auto align them and stack them.  Once this is done you may need to crop the image to cut out some artifacts depending on how much the perspective changes during the series shoot.

Why Use a Dedicated Macro Lens

You can see from the above that it is certainly possible to get good results using a kit lens and an extension tube (really good results if you put more time in) however there are some reasons why you might want to consider stepping up to a specialized lens.

Improved Image Quality

More expensive glass will get you higher image quality apparently although honestly I don’t think its really that much of a difference. I have my doubts you could show someone 10 random images taken with the Tamron and 10 with the kit lens and they could sort them without looking at metadata.


If you get a dedicated macro lens you’ll probably get a much wider aperture which while not especially useful it will mean that you wont be shooting wide open which will help your image quality.  It will also help you capture images of creatures that move a little faster than plants, especially if you don’t have additional lighting.  Of course wider apertures mean shallow DOF so keep that in mind.

Focal Length / Working Distance

For me this is the biggest reason to go with a dedicated lens, the focal length of the lens and the fact that a real macro lens will give you a 1:1 magnification without messing with extension tubes means you’ll have a much easier time.   The 1:1 working distance (the distance between your focal plan and your lens when you are at 1:1 magnification) is generally a lot better with a dedicated lens.  For example here are the more common macro lens working distnaces:

  • Canon 60mm – 0.09m
  • Canon 100mm – 0.149m
  • Tamron 90mm –  0.139m
  • Sigma 105 – 0.142m

Sources: here and here

One of the reasons the kit lens shots above are from a different angle is because I had a really hard time getting the framing correct due to the seriously reduced focusing distance on the kit lens with just the 21mm extension tube.  I had hoped to use more extension tubes but just the 21 proved enough trouble that I didn’t bother.  Here are a few shots of the setup showing just how close the lens had to be to the flower

This slideshow requires JavaScript.

Obviously you don’t want subjects like flowers close to the outer glass of your lens, even if that was not an issue the shadow from the lens will start to cause you a lot of problems.  Obviously is you want to capture images of live insects you also wont be able to get that close either.

When starting macro photography extension tubes are the way to go – its not very often in photography that 20 dollars / euro can open up the opportunity for something completely new.  Eventually you might want to go down the road of a dedicated macro lens but I wouldn’t rush to it

If you try something like this yourself please post your results




Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s