Quantitative comparisons of macrophotography with and without Lieberkühn reflectors

In order to quantitatively examine the effect of the the 3D printed Lieberkühn reflectors I described previously, I came up with two image quality metrics relevant to their use, both measured on the “dark side” of the image subject. The metrics we will look at today are average intensity and, as a measure of contrast, the standard deviation of pixel values on a line trace.

I’ll be using the Megachile photo from the previous post for these analyses.

The first line trace begins at right eye and extends back behind the wing:

DSC_0523redLineRightEye

DSC_0524redLineRightEye

RightEyeTraceValues

If we plot these values together, we see that the photo taken with the Lieberkühn (values in black) is brighter and brings out a lot more detail, while the photo taken without is relatively flat and dark. We see similar results for second and third traces, taken across the tegula and along the wing.

DSC_0523redLineAcrossThorax

DSC_0524redLineAcrossThorax

AcrossThoraxTraceValues

DSC_0523redLineWing

DSC_0524redLineWing

wingTraceValues

If we compare the average values:

octave3.2:25> mean(RE523(:,2)) %with Lieberkühn, right eye trace
ans = 102.00
octave3.2:26> mean(RE524(:,2))%w/o Lieberkühn, right eye trace
ans = 54.093
octave3.2:28> mean(AT523(:,2))%with Lieberkühn, trace across tegula
ans = 81.553
octave3.2:27> mean(AT524(:,2))%w/o Lieberkühn, trace across tegula
ans = 51.288
octave3.2:29> mean(W523(:,2))%with Lieberkühn, across the wing
ans = 103.85
octave3.2:30> mean(W524(:,2))%w/o Lieberkühn, across the wing
ans = 53.045

We see that taken together, the averages of the plots from the photo taken with the Lieberkühn are about 80% brighter than those without.

mean(Lieberkühn)/mean(no Lieberkühn) = 1.8142

octave3.2:56> std(RE523(:,2)))%with Lieberkühn, right eye trace
ans = 20.316
octave3.2:55> std(RE524(:,2))%w/o Lieberkühn, right eye trace
ans = 7.3926

octave3.2:54> std(AT523(:,2))%with Lieberkühn, trace across tegula
ans = 17.737
octave3.2:53> std(AT524(:,2))%w/o Lieberkühn, trace across tegula
ans = 13.227

octave3.2:52> std(W523(:,2))%with Lieberkühn, across the wing
ans = 12.746
octave3.2:51> std(W524(:,2))%w/o Lieberkühn, across the wing
ans = 8.2902

Using standard deviation as a metric for image detail, we get an increase of about 75% in standard deviation over the dark photo by using the reflector.

octave3.2:30> (20.316+17.737+12.746)/(7.3926+13.227+8.2902)
ans = 1.7572

The averages, standard deviation etc. may seem a bit redundant at this point; you don’t need to plot a pixel-value profile to see that the image with the reflector is much brighter and more detailed than the photo taken without.

3D Printable Lens Hood Design

A lens hood is a shade that blocks out-of-frame light from reflecting off of the internals within the lens. This minimizes lens flares, so you can add them later in post. Just kidding.

Another form of lens flare is less obvious (and I don’t think J.J. Abrams uses it). It manifests as a haze across the majority of the frame making the image appear washed-out, and it never looks good. Unlike deliberate lens flares, it’s not obvious in the image itself where it comes from and doesn’t look dramatic.

To get the most effect from a lens hood, it needs to block out as much unwanted light as possible without actually showing up in the frame. This means that for any given lens at a certain focal length and field of view there will be a best angle for your lens hood.

The wikipedia article for angle of view gives an equation depending on the focal length and sensor size.

2cdot tan^{-1}(frac{d}{2f})

The variable d is the dimension of interest. For a lens hood with a simple circular cross section throughout the longest dimension should be used, e.g. the diagonal length of a typical rectilinear sensor. The doubling factor can be omitted if you want to work the angle in relation to the optical axis, rather than the total angle.

The lens hood below is a general purpose lens hood (also 3D printed) for lenses with a 58mm filter thread diameter. It flares out a bit, and the angle is wide enough to use with a ~27mm focal length lens.

DSC_0432

The images below show essentially the same 58mm diameter lens hood optimized for 16mm, 35mm, and 50mm, in order from left to right. The length of the hood in each case is 16mm. The shorter the focal length of the lens (and the larger the image sensor) the wider the angle, and the lens hood angle increases accordingly.

lensCapsEpi

lensCapsSide

lensCapsSideSide

So far, I have printed the general purpose lens hood, which errs on the side of wide-angle caution. Once I have the additional test pieces in hand, we’ll give ’em the old Pepsi challenge.