Photogrametry is a software technique where an object or place is reconstructed into a textured 3D model using a lot of photographs. Shooting pictures of small figures such as those hand-painted miniatures is quite different from taking the pictures of large objects, or even just small objects. In photogrametry we need the subject to be in full focus for it to work and not get the image discarded by the 3D reconstruction software. With miniatures, we have to deal with the shallow depth of field which make it difficult to have the whole subject in focus. In this tutorial I will show you how to take the pictures, calibrate your camera, crop the image while preserving the calibration, and then reconstruct the 3D model using 3DF Zephyr.
I had tried using the open source software Meshroom. But not only it can be 5 times slower, it does not have an easy way to make the masks of the object (required when you use a turntable) and you need to patch the application in order to be able to use masks. Still, Meshroom can be an amazing software in the future once some of these features get implemented.
There are different camera options to take the pictures of your minis. You can use a cell phone, a point-and-shoot camera, mirrorless cameras, or DSLR cameras. Even though a DSLR camera will give you the best quality you can still obtain a pretty good 3D reconstruction using just your cell phone camera.
First I will start describin the main properties of a camera using my Sony a5000. This properties are focal length, aperture, shutter speed, ISO sensitivity, and distance to subject. If you use a cell phone it is most probably that the distance to subject is the only thing you can change.
As the main issue with taking pictures of the figures is to have it in full focus, I will first show the focus calibration pattern I designed to determine the focus plane and depth of focus.
To test and calibrate the focus plane and depth of focus I use the next pattern. The center is the focus plane and the sides are walls at 30deg with rulers in mm that tells the depth of focus distance (not the wall's length). You can download the focus pattern from this link.
The focus pattern should be place at the center of the pattern base to align the focus plane and use the depth of focus rings to determine the area of full focus. Once you have calibrated your camera and it position to obtain the desired focus area, you can be sure your figure will be in full focus as long as it is inside the depth of focus ring.
The next pictures shows my photograph stage.
I made the half light box using a cardboard box covered with white letter sheets. The turn table was 3D printed using this model Fully 3D-printable turntable from thingiverse. But you can use any round base with a pivot in the center so you can freely rotate it. I cut a round cardboard base to glue the focus pattern base. I use two dimmable LED lamps with light temperature adjustment from Amazon. And a tripod for the camera and cell phone.
No matter which camera you use, you always are going to need a lot of light and a tripod. If you use several lamps make sure they all have the same color temperature, otherwise the color of the figure capture by the camera will no be what you see. Any movement of the camera when you take the picture will affect the sharpness, so always use a tripod and configure the camera with self timer. In this way, when you press the trigger the picture will be taken 2 or 3 seconds latter, free of any movement you caused by pressings the button. Also the tripod is important if you don't have much light and you exposure time is too long.
To take the pictures I use my Sony a5000 with the stock lens 16-50mm. All the photos were shoot in RAW format and the post-processed using Capture One Express for Sony which is free for Sony camera. Also I will show results using macro extension rings and a 7Artisans 60mm f1.8 macro lens. After this you will know if it worth to buy the cheapest macro lens that cost \\(160 dollars, a cheap extension ring that cost around \\)16 dollars, if the stock lens will do the job, or event a cellphone camera works..
Lets start with the Focal length. It refers to the distance from the image plane (camera sensor) to the lens nodal point. The lens nodal point is where all the light from a distance image converge to a single point. Shorter focal length yield to wider view-angles but smaller images, while longer focal length give narrow view-angles but larger images. This is refered as zoom in point-and-shoot cameras, but it will appears as focal length in semi-profesional, professional, or any other camera that has a manual mode.
The next pictures shows the comparison of typical focal lengths while keeping the distance from the subject to the camera constant. With shorted focal length the subject appears smaller. Longer focal length applies a zoom.
The next pictures shows the same subject but preserving the same image size. You can see how it change the view angle. With longer focal length the subject is more flat, but with smaller focal angle you capture more background. Still, with small figure the differences over the subject are too small.
The aperture define how much light enters the camera and is measure in F-Stops. You can find more info in this wiki f-number. With the Sony a5000 with the stock lens 16-50mm at focal length of 50mm the maximum aperture is F5.6. Smaller numbers means more light. The next picture compare the same focus calibration pattern with apertures F5.6 and F16. (Move the slider to see the differences).
Using a smaller aperture (higher F-number) you can get more depth of focus. But in this lens with apertures smaller than F16 the image start to get blurred due to diffraction. The blur by diffraction is different from the blur due to out of focus. With diffraction even the plane at focus gets blur, it applies to the entire image. It depends on each lens at which apertures it start to suffer from diffraction.
Also with smaller aperture you need a slower shutter speed or longer exposure time. As less light enter the camera you need to expose the sensor longer to the light.
I have found with the stock Sony a5000 lens that an aperture between F11 and F16 gives a good depth of focus with enough quality without suffer noticeable diffraction. In contrast, the 7Artisans macro lens is only usable up to F11, at F16 you lose too much details due to diffraction, but the F-stop scale in the 7Artisans seems to be different as you will see latter.
Another parameter that can be use to obtain more depth of focus is the distance to the subject. The closer you are the shallow the depth of focus will be. Of course if you are farther away from the subject it will be smaller in the picture. The trade off between distance and depth of focus depends on the subject size. The next two pictures shows the depth of focus with aperture F16 at two different distance. Observe how the depth of focus change when they are compare side to side.
A small full focus picture is much better than an out of focus bigger picture. Any picture with size larger than Full HD will work.
The shutter speed defines for how long the sensor will be expose to the image. This time depends on the amount of light, the aperture size, distance to the subject, and the sensor sensibility or ISO. But the amount of light is fixed by what you have in your stage. The aperture and distance of the subject are fixed by the required depth of focus. Then the only free variable would be the sensor sensibility or ISO.
You will want to exposure your image long enough to capture all the color, but without sature the image. Saturated areas will all look white with complete lost of details. When this happens you have over-exposure your imge. On tne oposite, when the shutter speed is too low you will not calture enough light and you will under-exposure lossing details. This areas will look black and noisy.
Don't trust your camera display as the LCD backlight and gamma if the display will give you a fake representation of what the image will look like. Always take pictures with different speed and the compare in your computer, then use the speed that gives you the best result.
The sensor sensibility or ISO tells exaclty that. With higher ISO number the sensor is more sensible allowing you to capture images in low light condition. But also with higher ISO number the image will have more noise. Any ISO bellow 400 will give good results. And as you will be using a tripod for your camera, then you can set the shutter speed to exposure the sensor long enough to caoture a good image.
In this section I show what pictures can be taken with the next lenses: stock Sony F3.5-5.6 16-50mm, stock Sony F3.5-5.6 16-50m with Meike 10mm extension tube, and 7Artisans F2.8 60mm macro.
The numbers F3.5-5.6 16-50mm engraved in the lens means the maximum aperture at 16mm is F3.5 and at 50mm is F5.6. The focus distance goes from 26cm to infinity. The zoom factor of the lens is 0.25 or 1:4.
At 10mm length tube is inserted between the lens and the camera extending the focus length to 60mm and proving image zoom. But the focus distance is modified to a minimum of 19cm and maximum 36cm. Even the extension provides zoom suitable for macro photography, it does not improve the depth of focus. The zoom factor is increased close to 0.5 or 1:2.
This is a macro lens with 1:1 zoom factor with focus distance of 26cm and is reduce to 1:2 at 30cm, 1:3 at 35cm, 1:4 at 40cm, 1:5 at 45cm, and stay close to 1:6 from 50cm to infinity. Clearly this lens is targeted to shoot very close to the subject but still can work as a portrait lens. But still for portraits or landscapes the stock Sony F3.5-5.6 16-50mm can do a better job. But let see how it perform for what we need, that is miniature shooting where we are not too close nor too far.
Next is a comparison between the Sony and the 7 Artisans lenses.
With Sony lens shoot at ISO200, 1/80s, and F16. With 7Artisans lens shot at ISO200, 1/80s, F11.
Here the images were post-processed to match the light, size, and perstective. There is almost no different in the depth of field both can achieve at the given aperture. But in the Sony lens you can reduce further the aperture (high F-number) but in the 7Artisans F11 is the limit, above this the difraction is to high. We see that the F-number is different for these two lens where an F16 in the Sony is equivalent to F11 in the 7Artisans.
The 7Artisans macro lens allows to take bigger pictures standing farther from the object but you will not gain much depth of focus with miniatures. The 7Artisans is a greate lens for macro photography but for miniatures, where you need the whole object in focus, it performs the same job as the stock Sony F3.5-5.6 16-50mm. With the Sony lens you can still increase the F-number to gain more depth of focus.
Every lens produce some distortion in the image. The process of camera calibration is intended to, as exactly as possible, extract the parameter of the lens that produce the distortion, and use them to un-distord the image. The idea is to avoid having the 3D reconstruction software to try to obtain this distorion parameters, which for picturs of miniatures taken with a turn table can give unexpected results. For entire escens where you preserve all the image and have a background as referencenyou can relay completelly on the software. But with minis the backgorund is white, and as you saw before the figure can give you enough information event to tell you the focal length.