Introduction

This blog is a user's perspective on the Micro Four Thirds camera system. Read more ...

Lens Buyer's Guide. Panasonic GH4 review.

My lens reviews: Olympus 9mm f/8 fisheye, Lumix G 12-32mm f/3.5-5.6, Leica 25mm f/1.4, Lumix X 12-35mm f/2.8, Lumix X 35-100mm f/2.8, Sigma 30mm f/2.8, Sigma 19mm f/2.8, Lumix X PZ 14-42mm f/3.5-5.6, Lumix X PZ 45-175mm f/4-5.6, Olympus M.Zuiko 45mm f/1.8, Panasonic Lumix G 100-300mm f/4-5.6, Panasonic Leica Lumix DG Macro-Elmarit 45mm f/2.8 1:1 Macro, Panasonic Lumix G 45-200mm f/4-5.6, Panasonic Lumix G 20mm f/1.7 pancake, Panasonic Lumix G 14mm f/2.5 pancake, Panasonic Lumix G HD 14-140mm f/4-5.8, Panasonic Lumix G HD 14-140mm f/3.5-5.6, Panasonic Lumix G 8mm f/3.5 fisheye, Lumix G 7-14mm f/4, Samyang 7.5mm f/3.5 fisheye, Tokina 300mm f/6.3 mirror reflex tele, Lensbaby 5.8mm f/3.5 circular fisheye lens
The blog contains affiliate links. As an Amazon Associate I earn from qualifying purchases.
Showing posts with label distortion correction. Show all posts
Showing posts with label distortion correction. Show all posts

Tuesday, 15 May 2012

Geometric distortion correction

Most of the Micro Four Thirds lenses need geometric distortion correction applied for the output images to become rectilinear. This is done totally seamlessly by the camera and software, both for JPEG and RAW images. So the user never notices that the image, as seen by the camera through the lens, is not rectilinear in the first place.

This is in contrast to older DSLR systems. In these systems, there is an optical viewfinder, in which the users sees exactly what the sensor sees, through the lens. With a DSLR system, the lens must be rectilinear, otherwise, the user will be appalled by the geometric distortion when using the camera.

Here is an illustration of two basic kinds of distortion: Pincushion distortion (left) and barrel distortion (right):


In reality, the geometric distortion might very well be more complicated than what is illustrated by these simple models.

I have previously tested the geometric distortion properties of some Micro Four Thirds lenses, and I found that virtually all lenses featured some distortion correction. Especially wide angle lenses, or the wide end of zoom lenses. Since this time, I have acquired some new lenses, and I wanted to test them in the same way.

Again, I have done the tests by taking a pictures of a tiled wall. The images look like this:


Since I am only interested in the geometric distortion, I have increased the contrast so that the images become monochrome. I also superimposed the corrected out of camera JPEG images (black) onto the original RAW uncorrected images (red).

I included the appropriate adjustment needed. The adjustment numbers in percent refer to the "Lens Distortion" filter in The Gimp, an image processing software. Of course, to become rectilinear, some lenses might require more complicated adjustment than the simple model given by the "Lens Distortion" filter. So these figures are just intended to be approximate relative indicators of the degree of distortion. A positive figure indicated barrel distortion, while a negative figure indicates pincushion distortion.

Here is a comparison of the uncorrected and corrected images for some lenses.

Panasonic Lumix 14mm f/2.5 pancake: -16%

There is a significant barrel distortion, which is corrected in the in-camera JPEG image. However, there is some residual barrel distortion even in the corrected image. I have noticed this previously. In fact, the lens is rectilinear (after correction) at long focus distances, but has some barrel distortion at close focus distances. In this example, we see the barrel distortion at close focus distance. This is not an uncommon behavior for lenses that feature internal focus.


Olympus M.ZD 45mm f/1.8: 0%

No distortion correction at all. It looks like there is a small amount of pincushion distortion, though, so perhaps there should have been some in-camera correction done by the camera.


Panasonic X PZ 45-175mm f/4-5.6 @ 45mm: 0%

No distortion correction at 45mm.


Panasonic X PZ 45-175mm f/4-5.6 @ 100mm: +5%

There is some pincushion distortion correction at 100mm, but not a lot.


Panasonic G 100-300mm f/4-5.6 @ 100mm: 0%

No geometric distortion correction at 100mm.


Summary

Including the results from my previous study, I can present a table with the relative distortion corrections of various lenses:

LensFocal lengthRelative distortion correction
Lumix G 20mm f/1.7 Pancake20mm-11%
Lumix G 14mm f/2.5 Pancake14mm-16%
Lumix G 14-42mm f/3.5-5.614mm-18%
Lumix G 14-42mm f/3.5-5.630mm0%
Lumix G 7-14mm f/47mm-17%
Lumix G HD 14-140mm f/4-5.814mm-17%
Lumix G HD 14-140mm f/4-5.830mm-4%
Lumix G 45-200mm f/4-5.645mm+1%
Lumix X PZ 45-175mm f/4-5.645mm0%
Lumix X PZ 45-175mm f/4-5.6100mm+5%
Lumix G 100-300mm f/4-5.6100mm0%
Olympus M.ZD 45mm f/1.845mm0%
Panasonic Leica Lumix DG Macro-Elmarit 45mm f/2.8 1:1 Macro45mm0%
Lumix 8mm f/3.5 fisheye8mm0%
Sigma 30mm f/2.88mm0%

Conclusion

We see that wide angle lenses and zooms typically feature barrel distortion (negative figure) in the wide end. On the other hand, longer lenses are often not corrected, or are corrected for a small amount of pincushion distortion (positive figure). The in-camera distortion correction is some times insufficient, for example we've seen that the Olympus M.ZD 45mm f/1.8 and Lumix G 14mm f/2.5 pancake lenses feature some geometric distortion in the short focus range, while behaving better at infinity focus.

There are some who have speculated that Leica-branded lenses are not subject to any software corrections. I have looked at the Panasonic Leica 45mm f/2.8 1:1 macro lens, and found no indications of software adjustments to the images. However, I still don't believe that statement. One of the first cameras for which the software corrections were widely discussed online, was the Panasonic Lumix LX3 high end pocked camera from 2008. And it does feature a Leica-branded lens, and quite clearly, there is a significant barrel distortion in the wide end of the zoom, which is corrected by software.

Sunday, 6 March 2011

Geometric distortion correction

Many Micro Four Thirds lenses feature in-camera geometric distortion correction. Two examples are the Panasonic pancakes, Lumix G 14mm f/2.5 and Lumix G 20mm f/1.7. Both have pretty similar distortion correction needs. When converting the sensor output to the out of camera JPEG image, around 10% of the pixels in the border area are lost.

This is somewhat controversial. Some feel that a quality lens should not require further software correction. In fact, the lack of geometric distortion is a traditional sign of a high quality lens.

I think that this is mostly a non-issue. By allowing some aspects of the image to be adjusted in software, the lens designers can focus on issues which cannot be corrected in post processing. This has the potential of making the lenses better, at a smaller size, and potentially a smaller cost. Panasonic Micro Four Thirds lenses are adjusted for geometric distortion and some chromatic aberrations. The geometric distortion is also corrected in Olympus Micro Four Thirds cameras. At this time, though, Olympus does not correct chromatic aberrations.

To illustrate the geometric distortion done with various lenses, I have photographed a tiled wall with them, and shown the sensor output compared with the corrected JPEG output.

Here is an example pair from the Lumix G 20mm f/1.7 pancake lens:



uncorrected RAW output
JPEG image

Note that this is in no way a criticism of using RAW images. There are many RAW image converters which will do the distortion correction automatically and seamlessly, and you will never notice that there was any geometric adjustment done at all. I am using the RAW images to visualize the initial image captured by the sensor, as it is the only way to access it.

Here is a comparison of the uncorrected and corrected images for some lenses.  Since I am only interested in the geometric distortion, I have increased the contrast so that the images become monochrome.  I also superimposed the corrected out of camera images (black) onto the original uncorrected images (red).

I have also included the appropriate adjustment needed. The adjustment numbers in percent refers to the "Lens Distortion" filter in The Gimp.

Lumix G 20mm f/1.7: -11%



Lumix G 14mm f/2.5: -16%



Lumix G 14-42mm f/3.5-5.6 @ 14mm: -18%



Lumix G 14-42mm f/3.5-5.6 @ 30mm: 0%


Lumix G 14-140mm f/4-5.8 @ 14mm: -17%



Lumix G 14-140mm f/4-5.8 @ 30mm: -4%


Lumix G 45-200mm f/4-5.6 @ 45mm: +1%



Conclusion

Normal zoom lenses pretty consistently feature barrel distortion in the wide end. The tele zoom Lumix G 45-200mm appears to have some very small pincushion distortion, but very minor.

Some lenses that do not feature any geometric distortion correction are the Lumix 8mm f/3.5 fisheye and Panasonic Leica Lumix DG Macro-Elmarit 45mm f/2.8 1:1 Macro lens.

Sunday, 28 November 2010

Lumix 14mm, insufficient distortion correction

Just like a host of other Micro Four Thirds lenses, the Lumix G 14mm f/2.5 pancake lens utilizes in camera distortion correction.

However, when using the lens on the Panasonic GH1 camera, I've noticed that the distortion correction is not sufficient. There is still some residual barrel distortion after the in camera correction.

Here are a couple of examples. First, let's look at an example at a close focus distance, close to the minimum focus distance of the lens:

Corrected JPEG
Uncorrected RAW

In this example, even when looking at the small image (above, left), it is easy to see that there is still some barrel distortion in the upper, horizontal line. The line is not straight. You can click on the image to view a larger version of it.  The corrected image to the left is the JPEG output from the camera.

The right image shows the image as captured by the sensor, without any distortion correction at all.  I used the UFRaw RAW processing software.  But any software that allows for disabling the distortion correction could be used for this purpose.

And one example with a longer focus distance:

Corrected JPEG
Uncorrected RAW

In this latest example with a longer focus distance, it appears that the remaining distortion is not so significant. I added a red, straight guideline to the left in the JPEG image, above left. You can see that there is some barrel distortion still, but not much.

Conclusion

It appears that when using the Lumix G 14mm f/2.5 pancake lens on a Panasonic GH1 camera, there is some residual barrel distortion. This is most apparent at shorter focus distances.

One could speculate why this is so. I don't think it is a firmware issue, since I have the newest firmware available for my camera.

Another speculation is that Panasonic chose to not correct all the barrel distortion, since that would have decreased the diagonal angle of view. The diagonal angle of view for this lens is specified to 75°. Further correction of the barrel distortion would reduce this figure, albeit with a small margin.

The Lumix G 14mm f/2.5 pancake lens uses internal focusing, and it is not uncommon that these designs lead to changes to the distortion properties, and field of view, at closer focus distances.

Thursday, 18 November 2010

Lumix 14mm distortion correction

Just like most other Micro Four Thirds lenses, the Panasonic Lumix G 14mm f/2.5 pancake lens is corrected for barrel distortion in camera. This is applied when looking through the viewfinder, when producing JPEG images or videos, and when using some RAW converter programs. So many users are probably not aware of this at all.

It is easy to see the effect of the distortion correction when opening the RAW image file in a converter program that allows for not applying distortion correction. One such example is UFRaw.

Here is an example image. It was taken at f/2.5, ISO 400, 1/13 second exposure. Both the out of camera corrected JPEG, and the non-corrected RAW image are shown below:

Corrected JPEG
Uncorrected RAW

It is apparent that there is some barrel distortion in the RAW image. To correct this requires about -14.5 adjustment in the Lens Distortion filter within The Gimp image processing software. This is slightly more than for the Lumix 20mm lens, for which I found that -13.5 was an appropriate adjustment.

This picture shows what sensor area is lost during this conversion: The area outside the white frame is unused when applying the distortion correction.



This corresponds to around 12% of the sensor area, and hence you lose around one megapixel of resolution with the normal 12 megapixel sensor. This is nothing to worry about.

The upside is that if you need a wider field of view, you can use the whole sensor output from the RAW file. The normal diagonal field of view for this lens is 75°. Using the extra sensor area output to the RAW file gives you around 80° field of view. Of course, this will not be distortion corrected, but as long as you don't photograph any straight objects, this shouldn't be any problem. For nature and people, this might not be an issue.

Framing your picture will be difficult, though, since the viewfinder only shows the image after the distortion correction. And you might experience more vignetting in the extreme corners.

Insufficient distortion correction

To my surprise, I noted that the distortion correction is in fact not fully sufficient. After the in camera distortion correction, there is still some residual barrel distortion, especially at shorter focus distances. You can note this in the top left image: The pillar to the left is not entirely straight. Also, the ceiling is slightly distorted.

It could be that newer cameras do a better job of correcting the distortion.