3

So my problem, as I said in the title is that I have an image that is in an perspective view and I to transform it into the orthographic view.

But as far as I can understand this example : enter image description here

the distance from the camera to the NearClip plane and to the FarClip plane is required.

I was wondering if I'm going completly wrong and if there is a way to accomplish that without knowing those distances?

If yes, I Suppose it's something easy such as a matrix multiplication, but after few hours of research, I turn to you searchin any help that can come...

Thanks a lot!

Best regards!

EDIT : I will explain the context, maybe it can helps. I have a Fish-eye camera that took a panoramic picture (like below, for example) enter image description here

And my final goal is to create 6 cubics (6 image that corresponde to the up, the down, right, left, front and back of a cube if you're in the cube). So I tried to use the equirectangular projection to create a picture that contains the 6 cubics.

But the problem is that the fisheye take perspective view. So my 6 pictures are perspectives. And I want them to be ortho... :'(

3
  • Just wanted to point, that if you only have the near clip, you don't have enough information from the 3D image to make a faithful transformation. Those projections are 3D -> 2D, you're asking for a 2D->2D after some information is lost.
    – xvan
    Apr 12, 2016 at 12:49
  • I'm not sure to understand. You think it's not possible? I will add informations to my post of the context, maybe it can help.
    – Raph Schim
    Apr 12, 2016 at 12:52
  • Look up at the sky (make sure tge view is not obstructed by a ceiling). See that big white disk? How large its orthographic projection should be? Jan 24, 2019 at 17:23

2 Answers 2

4

No this is not possible without making several assumptions. Distances or object sizes..

Of course you don't have any informaton of what is behind your objects from your perspective. This information is not available even if you had the distances.

If that was possible there would be no need for 3d-imaging or telecentric lenses.

Of course you can also assume that your objects are spheres. Then you know what to add in your reconstruction but in general this is not viable.

4
  • I added some informations. Even with those, you think it's not feasible to do what I want to do? /:
    – Raph Schim
    Apr 12, 2016 at 13:06
  • even if you had exact measurements of the boats' lengths and distances and what not the result would look very poor. in addition to your short focal length that causes the strong perspective you also have multiple other errors from the lens. otherwise your walkway would be straight, not curved
    – Piglet
    Apr 12, 2016 at 13:38
  • Well, it seems i'm going on the wrong way somewhere and there are some informations lost in the process. I'll try to find another way. Thanks :)
    – Raph Schim
    Apr 13, 2016 at 6:52
  • There are some frameworks and algorithms that will generate 3D data from a moving omnidirectional camera. Once you have 3D data you could generate an orthographic projection.
    – Rethunk
    Jan 25, 2019 at 2:40
2

This may be an old question, but the existing answer of "not possible" is not correct for pictures that are less extreme than the example. Photoshop has a Lens Correction tool, as does the free program Gimp. A tutorial for the Photoshop tool is at https://helpx.adobe.com/photoshop/using/correcting-image-distortion-noise.html#correct_lens_distortion_and_adjust_perspective showing it can be done through Choose Filter > Lens Correction. And though you would need to know specific measurements from the camera or scene to perfectly correct the image, you can get pretty close and use assumptions that some objects will have straight edges or certain lines will be parallel.

Gimp's tool is under Filters -> Distorts -> Lens Distortions, and some examples can be found at http://www.texturemate.com/content/how-easily-remove-lens-distortion-photos-using-gimp and there's a StackExchange answer for it at https://gamedev.stackexchange.com/questions/129415/converting-real-life-perspective-photos-into-orthographic-view-for-texture-creat

Neither of these may be extensive enough to un-distort an image from fisheye lenses, but these options are available to anyone who found this page and hopes to adjust an image with more common distortions.

1
  • Remarkable, I was downvoted for answering the question and providing a link to a demonstrations of exactly the feature the question asked - a conversion tool to change from perspective to orthographic. And that's basically the title of the linked StackExchange question. Granted it's not very effective for fisheye images, but that's an extreme which isn't needed for anyone trying to work with common photos. Feb 26, 2019 at 19:14

Not the answer you're looking for? Browse other questions tagged or ask your own question.