POV-Ray : Newsgroups : povray.general : How to get camera parameters from photohraph : Re: How to get camera parameters from photohraph Server Time
8 Aug 2024 10:21:12 EDT (-0400)
  Re: How to get camera parameters from photohraph  
From: Laszlo Vecsey
Date: 21 Mar 2001 21:14:13
Message: <3ab95ff5@news.povray.org>
The formula to project from 2D to 3D is very simple, so perhaps a similar
concept could be used in reverse to set up some initial points and then
build from there as a framework

To project the 3D position with values X,Y,Z onto a 2D screen, you use NewX
= Distance * X / Z where the Distance value is just some perspective scaling
value. The NewY is similarly Distance * Y / Z.

I got this out of some book called Flights of Fantasy, if anyone recalls it
or has a copy :)

So then just as the Canorma website describes, you could take the photo and
specify a couple points here and there, say the corners of the tops of the
buildings. You know the dimensions of some of the buildings, so put that in
and now those points have some kind of relationship. Perhaps you iterate
through and find a suitable camera angle and Distance that matches those
points.

"Disnel" <dis### [at] hlavacek-partnercz> wrote in message
news:3AA### [at] hlavacek-partnercz...
> Alf Peake wrote:
>
> > The few times I tried this I used a "try-and-see" method.
> > Select a regular object in the photo, make a pov wireframe cube and
> > rotate and scale until it matches the photo perspective. Repeat with a
> > second object to confirm camera position. A 10 frame animation of a
> > camera parameter helps.
> >
>
>
> Tried similar method, result is in p.b.i. But it takes a lot of time,
which I don't have for it and the result is very far from perfect :(.
> I think, that it must exist some mathematical method to do it
automatically....
>
> Disnel
>
>
>


Post a reply to this message

Copyright 2003-2023 Persistence of Vision Raytracer Pty. Ltd.