Jakub Trávník's resources

On Bokeh

The first part of article - On Bokeh Character - is here. I plan to produce a part about bokeh size and a part with some of my pictures related to bokeh theme later. I also plan to add more illustrations. This is work in progress.

Table of Contents

What is bokeh?

Bokeh is a word which photographers use for an appearance of out of focus parts of the picture. Each bright element in scene that is out of focus contributes to overall appearance. Bokeh can be observed best on bright dots which are out of focus and surrounded by dark background. Basic shape of such highlights is a filled circle. There are some geometry rules that tell how big it will be. Those are generally known. So I will skip this part for now. What I find interesting is character of bokeh.

On Bokeh Character

What affects bokeh shape?

The character of bokeh is best observed on small light sources. This character is mainly given by optical construction of lens. Most of modern lenses have rounded aperture blades. Older straight aperture blades produced polygonal out of focus highlights (if aperture was slightly closed). While the aperture blades are rounded in current lenses they may still be slightly visible in some aperture settings. Sometimes a single blade is slightly misaligned and more visible than others. I have seen too often marketing claim "rounded aperture blades produce pleasing bokeh". But rounded aperture blades are not guarantee of pleasing bokeh.

So what else goes into a character of bokeh? Sometimes what would be a circular out of focus highlight in the center of the image has a lemon shape outside of center, gradually more near borders and edges. This is caused by mechanical vignetting because the optical path in the lens is too narrow. Resulting shape is often a intersection of two non-concentric circles, often described as "lemon shape" or "cat eye".

Distracting bokeh or not?

While shape of bokeh can be slightly distracting if it is not circular, there is another issue with out of focus highlights. It's a distribution of light inside of them. The differences in light density around edges of out of focus highlights have these basic types (red graphs show light intensity from the marked areas):

bokeh types and light intensity graphs for each type

Why is there such light distribution?

Optimally corrected lenses focus all the entering rays from single point light source to a single point in image plane (at proper focus distance). Real lenses have various aberrations so what should be a point in image plane as produced by point light source is not a point, but rather some foggy ball. An aberration that causes light rays to be focused on different image planes depending on whether the ray goes through center of lens or sides is called spheric aberration.

Image below demonstrates spherical aberration. A lens being simulated (by my custom tool) has two biconvex elements, both with material with refraction index of 1.5. Both elements are spherical so whole lens has spherical aberration with no correction. Chromatic aberrations are not simulated. Light rays are randomly colored so you can easily follow each one.

ray traced example 1

Next image below uses white rays, but there are more of them to get better idea how this affects image plane.

ray traced example 2

Next image below uses 800 rays that can overlap to approximate whole light field generated by that the single light source in whole lens. Red vertical lines are sections of that light field that show how would the light appear if image sensor would be at that position - that is the bokeh.

ray traced example 3

Next two images show a different lens with two elements, almost same as lens above, but with corrected spherical aberration. Three surfaces of the two elements are same, but one has been changed from a sphere to a slightly different curve. Specifically, the equation for original spheric surface was x = 10*cos(alpha); y = 10*sin(alpha) while the new aspheric surface has this equation: x = 10*cos(alpha)+13*alpha^4; y = 10*sin(alpha).

ray traced example aberration corrected 1
More detailed light field:
ray traced example aberration corrected 2

Next two images show another lens almost same as lens above, but with overcorrected spherical aberration. Corrective part of equation was multiplied by 1.3 so the corrective effect stronger than it should be. Equation is x = 10*cos(alpha)+1.3*13*alpha^4; y = 10*sin(alpha).

ray traced example aberration over-corrected 1

More detailed light field shows the bokeh appearance is reversed in lens with over-corrected spherical aberration in comparison with the original lens which was completely uncorrected:
ray traced example aberration over-corrected 2

Now, this simulation above may look too artificial and unintuitive. Real lenses do not behave like this, right? They actually do. Just look at this picture below. It is taken by D90 with Sigma 50/1.4. The test target is here: bokeh-test-lines.png (you can try it with your lenses) and it is displayed on notebook LCD monitor. Camera is at angle so that left side of LCD is farther than focus point, right side is closer.

real bokeh sample of lens with under-corrected spherical abberation on bokeh-test-lines.png target

There are red and green colored edges of bokeh - that is longitudinal chromatic aberration. If you ignore red and green colored edges, it corresponds pretty well to the simulated sample of under-corrected spherical aberration, displayed (again) below:

ray traced example 3 (again)

Implications of lenses with under-corrected or over-corrected spherical aberration is that:

With such knowledge, following types of classic lens behaviors will not surprise you (numbering is mine, non-standard, but I will use it for the rest of the article):

Bokeh Samples

Sigma 50/1.4 DG HSM

Samples of Sigma 50/1.4 DG HSM which mostly belongs to type 3 - the rear bokeh has softer edges and front bokeh has more noticeable edges (note: both pictures are JPGs in landscape picture control with sharpening value 5 of range 0 to 9):

sigma 50/1.4 bokeh example overview
sigma 50/1.4
        bokeh example profile

But things are not so simple when used on full frame camera. Background bokeh outside of APS-C frame is distracting. Look at two pictures below. The first is at f/1.4, the second is at f/2.5, both out of camera JPEG taken with Nikon D600. Both show that in about APS-C frame the Sigma 50/1.4 has smooth background bokeh, while near corners, sides and elsewhere outside of APS-C frame, the bokeh is not smooth, it is edgy. Just compare center area with bottom right corner. It is also quite triangular in corners.

sigma 50/1.4 bokeh on full frame at f/1.4 outdoor
Sigma 50/1.4 outdoor at f/1.4. Click here to see full 24MP picture.


sigma 50/1.4 bokeh on full frame at f/2.5 outdoor
Sigma 50/1.4 outdoor at f/2.5. Click here to see full 24MP picture.

Additional bokeh samples of Sigma 50/1.4 using bokeh-test-lines.png with focus distance around 1m, on tripod, at several apertures, Nikon D90:

sigma 50/1.4 bokeh summary

f/1.4 t=1/20s
f/2.0 t=1/10s
f/2.8 t=1/5s
f/4.0 t=1/2.5s
You can see there is some focus shift, but note that focus ring was not moved during those exposures (and camera was in manual focus mode). Best focus for f/1.4 is near center of screen, but best focus for f/4 has moved to the left (farther).




Nikon 50/1.8G AF-S

Nikon 50/1.8G AF-S has similar type of bokeh as Sigma 50/1.4. Note that Nikon 50/1.4G AF-S is different. Bokeh in background is smooth, bokeh in foreground has pronouced edges.

Nikon 50/1.8G bokeh on bottles

Additional bokeh samples of Nikon 50/1.8G using bokeh-test-lines.png with focus distance around 0.8m, on tripod, at several apertures, Nikon D90:

Nikon 50/1.8G bokeh summary

f/1.8 t=1/13s In fact there is no change visible between f/1.8 and f/2.0. Perhaps aperture lever is not well calibrated? Brightness change is due to shutter time change.
f/2.0 t=1/10s
f/2.8 t=1/5s
f/4.0 t=1/2.5s

Here is outdoor series of pictures with varying apertures:
f/1.8 f/2.2 f/2.8 f/4.0
Look how bokeh is smooth enough in the center. But it is not so smooth even near bottom and on sides. Note that this is DX frame. While Sigma 50/1.4 has also less smooth background bokeh outside center, the effect is only visible in FX frame.




Sigma 85/1.4 DG HSM

Samples of Sigma 85/1.4 which mostly belongs to type 1 (shorter focus distances), and to type 2 (longer focus distances). Both rear and front bokeh is fairly "flat" or normal at shorter distances, but front is slightly more smooth. At longer focus distances you can see edges very clearly. I would rather prefer more smooth rear bokeh, like I have seen in pictures of cheap Samyang (or Vivitar) 85/1.4, but that one does not autofocus. These were captured as JPG in portrait picture control with sharpening 5 of range 0 to 9.

sigma 85/1.4 bokeh example overview
sigma 85/1.4 bokeh example profile

Comparison of Sigma 85/1.4 background (rear) bokeh at shorter and longer focus distances:

sigma 85/1.4
        background (rear) bokeh for shorter and longer focus
        distances

These statues are in my favorite location for photography practice at the Vinohrady Cemetery in Prague. You can also see high amount of purple fringing near highlight-dark object for f/1.4 (left picture), somewhat less for f/2.0 and none for f/2.8.

Additional bokeh samples of Sigma 85/1.4 using bokeh-test-lines.png with focus distance around 1.4m, on tripod, at several apertures, Nikon D90:

sigma 85/1.4 bokeh summary

f/1.4 t=1/20s
f/2.0 t=1/10s
f/2.8 t=1/5s
f/4.0 t=1/2.5s
You can see there is no focus shift. Bokeh is neutral.





Sigma 30/1.4 DC HSM

Samples of Sigma 30/1.4 which mostly belongs to type 3 - the rear bokeh has softer edges and front bokeh has more noticeable edges (note: both pictures are JPGs in portrait picture control with sharpening value 5 of range 0 to 9):

sigma
        30/1.4 bokeh example profile
Unlike Sigma 85/1.4 and Sigma 50/1.4, this Sigma 30/1.4 has noticable polygon bokeh appearance at f/2 due to shape and position of aperture blades. The aperture blades are slightly rounded.

Additional bokeh samples of Sigma 30/1.4 using bokeh-test-lines.png with focus distance around 0.7m, on tripod, at several apertures, Nikon D90:

sigma 30/1.4 bokeh summary

f/1.4 t=1/20s
f/2.0 t=1/10s
f/2.8 t=1/5s
f/4.0 t=1/2.5s
You can see there is some focus shift, but note that focus ring was not moved during those exposures (and camera was in manual focus mode). Best focus for f/1.4 is near center of screen, but best focus for f/4 has moved to the left (farther).

Exceptions to above lens types

DC lens examples

Defocus Control (DC) is a name which Nikon uses for special lenses that allow to adjust bokeh type through variable correction of spherical aberration. It is a rare opportunity that allows to study transition between lens type 2 (front creamy), type 1 (neutral) and type 3 (rear creamy), all in one lens.

Nikon Nikkor 105 DC f/2

I have tested this lens with usual bokeh-test-lines.png with focus distance around 1.8m, on tripod, at several apertures and several settings of DC ring on Nikon D90. To keep the DC lens sharp, you should not set front/rear ring to higher number than what you use for aperture. If you fail to do, the DC effect will be stronger but image quality will be worse. In table below images that break this rules are marked with star *.

DC ring position \ Aperture f/2.0 f/2.8 f/4.0
DC F5.6 DC-F5.6 f/2.0 * DC-F5.6 f/2.8 * DC-F5.6 f/4.0 *
DC F4.0 DC-F4.0 f/2.0 * DC-F4.0 f/2.8 * DC-F4.0 f/4.0
DC F2.8 DC-F2.8 f/2.0 * DC-F2.8 f/2.8 DC-F2.8 f/4.0
DC F2.0 DC-F2.0 f/2.0 DC-F2.0 f/2.8 DC-F2.0 f/4.0
DC 0 neutral DC-neutral f/2.0 DC-neutral f/2.8 DC-neutral f/4.0
DC R2.0 DC-R2.0 f/2.0 DC-R2.0 f/2.8 DC-R2.0 f/4.0
DC R2.8 DC-R2.8 f/2.0 * DC-R2.8 f/2.8 DC-R2.8 f/4.0
DC R4.0 DC-R4.0 f/2.0 * DC-R4.0 f/2.8 * DC-R4.0 f/4.0
DC R5.6 DC-R5.6 f/2.0 * DC-R5.6 f/2.8 * DC-R5.6 f/4.0 *

Sample picture based on few entries from table above:

bokeh samples from above table for 105DC

Some notes

Apodization element/filter

Apodization (or apodisation) refers to literally cutting the foot. In optics, it has meaning that sharp transition at bokeh edge is modified. And this modification does not rely on spherical aberration (that is already explained in sections above) thus it does not share disadvantage that under- or over-corrected SA has on sharpness of focused image parts. You can imagine Apodization as aperture blades that would be partly translucent near edge so that there would be a smooth transition. Now I have not seen a lens with partly translucent aperture blades yet. But there are other ways to get this using an apodization lens element or an apodization filter with limitation that it would work best only at largest aperture as the effect will not adapt when the lens is stopped down. In past, only well known lens of this type was Minolta/Sony 135 STF f/2.8 t/4.5 (with apodization element). See here. There is also recent Fujifilm XF 56/1.2 APD with apodization filter. Note that Apodization filter/element does not play well with phase detect AF so the 135STF is manual focus and the Fujifilm 56APD focuses in contract detection only (even if camera has phase detect on sensor).

Apodization filter is a filter placed near aperture blades that is clear in center and gradually darker on sides. It can be made from glass, film or other plastics. I guess it is possible to convert any lens to STF type by including an apodization filter. Best placement is next to aperture blades. Placing such filter on front element may work with long faster lenses, but it will cause high vignetting too. Sample vizualization (Apodization filter has yellow color):

ray traced
        example apodization 1

ray traced
        example apodization 2

If you have successfully converted non-STF lens into STF, write me an email - I will link to your blog about that.
Here is a page of Markus Keinath who has been experimenting with various Apodization filters on different lenses and sent me email with link to his page: http://www.4photos.de/camera-diy/Apodization-Filter.html

Apodization lens element is concave lens that is not made from a clear glass, but rather from kind of gray tinted glass. Rays going through center of this lens element will be attenuated only a bit, but rays going through side will attenuate their light a lot. So effect is same like apodization filter, but it has different set of advantages and disadvantages in terms of lens design compared to buit-in filter.

Note that I have seen some claims that Apodization element/filter creates Gaussian profile of bokeh (like Gaussian blur effect in image editors) and that this bokeh is too smooth. I don't think that it has to be that way. In case of filter, the profile of attenuation transition is a design choice. Also once you stop down the lens a bit, you will get different profile, so even if at some apertures the effect is like the Gaussian filter, when lens is stopped down the bokeh will be less smooth.

There is also a way to simulate Apodization filter by using either multiple exposures with different apertures or by changing aperture during exposure. It is described below.





Outdoor bokeh comparisons

Comparison of Sigma 30/1.4, Sigma 50/1.4, Nikon 50/1.4 on DX and FX

I have taken my Nikon D90 (DX - APS-C frame) and friend's Nikon D3 (FX - full frame) with three prime lenses to Vinohrady cemetery to evaluate their background bokeh. There were two FX lenses: Sigma 50/1.4 DG HSM, Nikon 50/1.8G AF-S; and one DX lens: Sigma 30/1.4 DC HSM. Pictures are jpegs converted by ViewNX in Standard picture mode and each series has fixed white balance. Aperture ranges from wide open to f/4 in four steps.

Position of tripod was fixed, but cameras have different height between mount and bottom plate so there is some change, also while both Sigma 50 and Nikon 50 are marked as 50mm, the Sigma is about 46mm Nikon is slightly longer at 52mm.

Open a few of them in new browser tabs (middle size is enough for bokeh comparisons) and switch between them to compare.

Series 1

Series 1 full album - focus distance around 5m.
Here are links to middle size pictures:

DX Sigma 30/1.4 f/1.4 f/2.0 f/2.8 f/4.0
FX Nikon 50/1.8G f/1.8 f/2.2 f/2.8 f/4.0
FX Sigma 50/1.4 f/1.4 f/2.0 f/2.8 f/4.0
DX Nikon 50/1.8G f/1.8 f/2.2 f/2.8 f/4.0
DX Sigma 50/1.4 f/1.4 f/2.0 f/2.8 f/4.0
Series 1

Series 2 full album - focus distance around 1.5m.
Here are links to middle size pictures:

DX Sigma 30/1.4 f/1.4 f/2.0 f/2.8 f/4.0
FX Nikon 50/1.8G f/1.8 f/2.2 f/2.8 f/4.0
FX Sigma 50/1.4 f/1.4 f/2.0 f/2.8 f/4.0
DX Nikon 50/1.8G f/1.8 f/2.2 f/2.8 f/4.0
DX Sigma 50/1.4 f/1.4 f/2.0 f/2.8 f/4.0

What I see in both series is that Sigma 50/1.4 DG HSM has most smooth bokeh in background out of the three wide open, especially in APS-C subframe. On sides in full frame, the bokeh of Sigma 50 has slightly pronounced edges and it is more of triangle shape. Sigma 30 also has this triangle bokeh on sides, but even in its limited APS-C frame there is a lot of it.

Comparison of Sigma 85/1.4 and Nikon 105DC f/2 on FX

I have taken friend's Nikon D3 (FX - full frame) with these two lenses prime lenses to Vinohrady cemetery to evaluate their background bokeh. Pictures are out of camera jpegs standard picture mode, ISO 200. Aperture ranges from wide open to f/5.6 in four or five steps. Camera was on tripod and used with delayed exposure. Each line in table below was focused wide open and for particular DC value using AF in Live View (on the leaves on the right side) then switched to MF and exited Live View. Exposure was manual.

Lens + setting \ Aperture f/1.4 f/2.0 f/2.8 f/4.0 f/5.6
Sigma 85mm f/1.4 f/2.0 f/2.8 f/4.0 f/5.6
Nikon 105 DC front 4.0 f/2.0 f/2.8 f/4.0 f/5.6
Nikon 105 DC front 2.0 f/2.0 f/2.8 f/4.0 f/5.6
Nikon 105 DC neutral f/2.0 f/2.8 f/4.0 f/5.6
Nikon 105 DC rear 2.0 f/2.0 f/2.8 f/4.0 f/5.6
Nikon 105 DC rear 4.0 f/2.0 f/2.8 f/4.0 f/5.6

Samples based on pictures from above table: samples of Sigma 85/1.4 and Nikon 105DC

As expected, the DC has most effect outside of range recommended for best sharpness. Bokeh of Sigma wide open is very close to Nikon at f/2 with DC set to R2. Nikon at f/2 DC neutral a bit less smooth than Sigma and Nikon at f/2 DC R2. On the other hand Sigma bokeh becomes worse at larger focus distances as can be seen in its separate evaluation on this page (here above).





Somewhat innovative methods to get nice bokeh

I had this idea below, but I found it has been described by others before. For example here near the bottom.

External Links

Some articles that go deeper into character of bokeh than just tell the rules for size of bokeh:

Back to index - Jakub Trávník's resources.