Where can I find any information about methods, used in cvFindHomography?
The problem is I am getting dramatically differing results, when call this function with
different values of its 4th parameter (method).
This is not described in the book.
I have a couple of stationary cameras and one which can be turned to any direction.
The direction is determined with two angles, measured from some initial position.
My task is to find angles for rotating camera, so that it could show a point, selected on
a stationary camera.
I consider this as a task of finding a projection from one plane in 3D space to another
I have manually collected control points: (x,y) -> (phi, lambda)
where x,y are point coordinates on stationary camera, and phi, lambda are angles.
Then I calculate perspective transform matrix using either cvGetPerspectiveTransform or
cvFindHomography, if I have more than 4 points.
cvGetPerspectiveTransform gives me more or less satisfying result.
I used cvFindHomography in hope to improve the accuracy, append some control points,
however, it gives sometimes much worse results.
I try this of several camera sets, and sometimes the results are better, if I use LMEDS
and sometimes - RANSAC, and I would like to have only one method.
You can find the description of the determination of an homography in
the (very good) book "Multiple View Geometry" Hartley, Zisserman. It
explains RANSAC algo quite well, but I can't remember if LMEDS method is
The paper of Z.ZHang "Determining the Epipolar Geometry and its
Uncertainty: A Review" explains the LMEDS method. There are different
versions but ftp://ftp.inria.fr/INRIA/publication/RR/RR-2927.ps.gz
pretty complete but applied to Fundamental matrix determination (the
princip remaining the same for an homography).
About your task, I'm not sure I understood what you want to do :
You pick a point in the stationary camera. This point belongs to a 3D
plane, and you choose 4 (or more) points which are as well on this
plane. Then you want to display the first point in the rotating camera,
knowing the homography (relative to this plane) between the 2 views. I
have the feeling, reading your post, that the homography you compute is
between the 3d plane and the stationary camera, but what can you do with
If I did not understand your problem, the following will be helpless...
If I did, I was just wondering if the points you selected manually in
the stationary camera are coplanar (but I guess you did).
If yes, did you select corresponding points in the rotating camera
manually (at least for an initialization step, in order to begin a
For me, if you want to display a point selected on the first camera to
the second one, you have to determine the homography between the 2
views, and re evaluate the homography during the rotation.
Hope this helps
[Non-text portions of this message have been removed]
> About your task, I'm not sure I understood what you want to do :
> You pick a point in the stationary camera.
Yes, and I want to command the rotating camera to turn so that picked point
would be in the center of its (rotating camera) view.
Seems, you did.
> If I did, I was just wondering if the points you selected manually in
> the stationary camera are coplanar (but I guess you did).
> If yes, did you select corresponding points in the rotating camera
> manually (at least for an initialization step, in order to begin a
Of course, I have selected several points on both cameras (block corners, lights,
outstanding tree branches, etc).
They have coordinates in terms of pixels for a stationary camera and in terms of position
angles for rotating camera.
I think I can consider this task as a task of projecting an XY plane (image plane, given by
a stationary camera) to the phi-lambda plane which is imaginary coordinate plane,
connected to the rotating camera.
> For me, if you want to display a point selected on the first camera to
> the second one, you have to determine the homography between the 2
> views, and re evaluate the homography during the rotation.
I am new to this area and cannot figure out, how to do this.
Probably, this is obvious, however, I am missing some basics.