That should be the same as enabling profile corrections in the lens corrections panel in LR

Hi Francisco,

Indeed it should, provided that there are profiles for the lens used. However, in the Panorama merging module the actual (not generic) lens distortion at the edges can be determined if there is enough detail in the overlap zone between images and the lens is not decentered too much.

Thanks Bart, I didn't know that. In any case, if I understand correctly, that method requires more than one image to work and cannot be applied to a single image.

That's correct, two overlapping images are required to achieve that.

Imagine two images with barrel distortion, ideally overlapping the same scene fragment by 50% for the best result (and rotated through the entrance pupil to avoid parallax). The left side image will radially shift details to the right in the right half of the image. The same details in the right side image will shift radially to the left in the overlapping left half of the image. The image centers ar not distorted and they align.

Now the software adjusts the distortion parameter(s) for both images until they match between both images, just like the image centers did all the time for the undistorted optical center. That will unveil the distortion parameters with two images, even for more complex distortions, like combined pincushion and barrel distortion, e.g. moustache distortion.

There is a possibility to do this with one image, but then the subject matter must be a regular predictable straight lines grid, or a grid of dots, or modern architecture with many windows or balconies at regular straight line intervals. By instructing the Pano-software that straight lines must be rendered as straight lines, and setting multiple line segments, the software can calculate which distortion is required to really line up the line segments. Distortion is characterized and the parameters can be applied to other images which do not offer such features.

Part of this functionality is becoming available in LR/ACR as the so-called "Upright" functionality, which takes its clues from image features"and guesses what the geometry is supposed to be. This sometimes works to produce squared images. Distortion is more complex than simple tilt of the camera, and not all scene content offers enough clues to work on.

...There is a possibility to do this with one image, but then the subject matter must be a regular predictable straight lines grid, or a grid of dots, or modern architecture with many windows or balconies at regular straight line intervals. By instructing the Pano-software that straight lines must be rendered as straight lines, and setting multiple line segments, the software can calculate which distortion is required to really line up the line segments. Distortion is characterized and the parameters can be applied to other images which do not off such features.

Correct. Trees are also often good candidates for things that must be straight up and down.

Quote

Part of this functionality is becoming available in LR/ACR as the so-called "Upright" functionality, which takes its clues from image features" and guesses what the geometry is supposed to be. This sometimes works to produce squared images. Distortion is more complex than simple tilt of the camera, and not all scene content offers enough clues to work on.

I've tried the "Upright" functionality in LR 5 and found it next to useless. For very very simple images it worked but almost none of the images where I want to use it are simple.

GDC looks like a much better answer to the problem - except that it cannot yet be used with a single image

One option could be to take three images (e.g. like having a left and right reference images) go to photomerge and then crop to the desired frame. This may not work in all cases and definitely not for past images

Depending on the case:- Build your own lens correction profile with the adobe tool- Use the adaptive wide angle filter in PS (CC)