Mobile app version of vmapp.org
Login or Join
Cofer715

: How to undistort this panorama image in Adobe Photoshop Elements? I need to fix some panoramic images. The phone and its camera are good quality, so the panoramas are stitched nicely for what

@Cofer715

Posted in: #AdobePhotoshopElements #ImageEditing #Panorama #PhotoEditing

I need to fix some panoramic images. The phone and its camera are good quality, so the panoramas are stitched nicely for what I need; the fix required is basically pinching, warping, or distorting using a curved effect, because the resulting image often has straight lines shown as curves.

I'm using Adobe Photoshop Elements 10, which has a nice range of tools. I suppose I could download a different program if I needed to, but would prefer not as I'm under a lot of time pressure. (If Elements 10 takes plugins and there is a good plugin for this, better than built-in tools, that would be fine)

I don't need to fix these photos to professional standards, just enough that they look casually okay, so the person I send them to can get a better sense of the actual layout without having to work out what's straight and what isn't - basically reduce the gross distortion to a minor distortion.

Tools tried (I'm not very experienced so maybe they work and I just don't know it):


The "Free Transform" tools don't seem to let me select midpoints of the edge of an image and move them in or out.
Adobe Help says to use pinch or warp, using filters rather than transformations.The Pinch tool seems to have a maximum effect of only 600px and doesn't let me control the effect appropriately for the problem (it calculates the effect across the diameter of tool, instead of letting me specify a curve which indicates how much the effect is and smooth it into the image as I would like).The Warp tool doesn't seem to allow the edges to be distorted to match the curves created by panorama imaging; it warps the interior near a given point only.
The "Correct Camera Distortion" tool is closer to what I need, but I can't find a way (if one exists) to define a line I consider "straight". It also insists on distorting all 4 sides equally which isn't helpful either (as you can see in the sample image below).


How can I do it?

This is a thumbnail of a typical image I'm trying to fix. The original is about 6000 px wide:



This is the kind of effect I need (the line in the middle is roughly correct):


The diagram below tries to show the transform or filter in abstract terms. It lets me specify an area to be distorted, and I drag some points on the edge to where they should be mapped to, and the area is smoothly distorted as I've tried to show. (There is no need to fill in the space created between the original edge and new curve, it can be ignored). I'm not saying it has to be this kind of effect - the photos above show what's actually needed - but this might give an idea how I think it could be done:

10.03% popularity Vote Up Vote Down


Login to follow query

More posts by @Cofer715

3 Comments

Sorted by latest first Latest Oldest Best

 

@Gail6891361

I finally found a good answer, which I'm posting here because I couldn't find the answer anywhere else, either here or online.

The tool needed is to distort (or undistort) a path, so that the path becomes straight. I found some tools seem to have such a tool (see list below), but Photoshop doesn't. Googling other tools or the general phrase "bend along a line" may help find other programs. But in the end I found a way to do it in Photoshop.

There are several ways to fix this, but the big ones are "warp" and "perspective warp". "Puppet warp" also has uses but it's also very much harder to keep smooth. The first two tools can be used in a few ways:

Using "Perspective Warp"

There are two techniques with this tool, use either, both or mix them as needed.

First, if you have specific areas where you want lines to end up straight (either horizontal or vertical), use this tool to define quadrilaterals ("quads") which line up with those lines. Then switch to "warp" mode in the toolbar and shift-click all the lines that need to be made vertical/horizontal. You might need to define some areas that are straight and stay straight, so it doesn't try to warp areas outside the part you want to straighten.

This has the advantage that it auto-warps a large area of distortion into nice straightness with little effort and very little distortion. Good for buildings, for example. If the bending is more at the edges than the middle (common with camera distortion) then define a few of these, link them to each other, and it'll straighten all of them if needed.

But there's a second way to use this tool. Suppose you want to unbend, (or equally, you want to stretch or distort) a part of the image but it doesn't have straight edges as above. So you can't auto-straighten is. Instead, define a mesh of your choosing, using this tool. Choose "natural" points for your image - they don't have to be in any particular place. The edges don't have to be any specific direction. Let the "quads" join up at their corners. Now when you go to the warp view, you can move the points to where they should be, and it'll give you a nice smooth warp on the contents of each quad.

An example of using this is to expand a bit in the middle of an image, "pushing" the part that's on one side, further away. This tool will do it.

Here's an example of that second use, which I'm using to fix the scale of the right side of a fence in an image distorted by the camera's built-in panorama stitcher. The above is the original and the warp quads I used, below is the warped positions, including the yellow lines to show where I forced horizontal (only). Crude and far from perfect but shows what I mean:



There's one small trick I would mention - if you define a few quads outside your workspace, you can pin their corners fixed, so in moving your quads it doesn't warp or move the rest.

There is one issue with this tool - as soon as you move any corner of a quad, all the other points shift. It makes it unnecessarily tricky to warp the quads exactly as one would like, as the nearby ones shift each time (though not impossible). It's still the smoothest bet for this kind of issue, in Photoshop, that I've found. If anyone knows a way to prevent other points shifting when one point is moved, please post it as a comment below and I'll update.

Using "Warp"

The key to the warp tool is the warp toolbar. It automatically gives you the freeform warp tool, but in the toolbar there's a dropdown with arches, shells, you name it. So there are many warp shapes. They might do what you need.

Finally, using "Puppet Warp"

I've kept this till last because for this work, it's not so helpful. You can get it to do any warp though, but the downside is, the above warps both work on smooth straight edges. This one doesn't. So you get a much more "fluid" effect, which is good for some things. But if unbending a curved edge, the above two tools you can break your curve into short segments that are roughly straight, and they will give you an almost perfect smooth warp. This tool might give you more of a pincushion effect at the edge. So it's much harder to keep "almost-straight-but-curved" from becoming "straight but rippled".

Other tools said to have this ability (I haven't checked these, feedback welcome)


HumanSoftware HSCEdit
PhotoLine
Nuke Studio
Gimp (?)
Possibly some Photoshop extensions (?)

10% popularity Vote Up Vote Down


 

@Sarah814

You do not need any curve unbending, but different perspective corrections. Your stitched images gave all different perspective to the long house. Here is a screenshot from GIMP. The leftmost snippet is under the correction. The canvas size must be made large enough before the correction to avoid cropping.



You can try this before stitching the images to make the job easier to the stitcher which oviously handles only the seams ok.

Search for more clever stitcher. If you are lucky, you can get the job done manually.

10% popularity Vote Up Vote Down


 

@Moriarity648

The "correct camera distortion" filter can fix basic lens barrel distortion, which is what's happening in your photos. More info here: www.dummies.com/photography/digital-photography/photo-editing/correct-camera-distortion-in-photoshop-elements-10/
But there's no way to define lines like that in Elements, but the full version of Photoshop CC has a more advanced Adaptive Wide Angle filter which does allow that. Perhaps you could download and install a trial - it lasts for 30 days.

10% popularity Vote Up Vote Down


Back to top | Use Dark Theme