- All Implemented Interfaces:
Estimates homography between two views and independent radial distortion from each camera. Radial distortion is modeled using the one parameter division model . Implementation based on the 6-point algorithm in  that solves 2 quadratic equations and 6 linear equations. See Tech Report  for the final form of equations used in code below.Undistortion model:
f(x,y) = [x, y, 1 + λ(x**2 + y**2)]Twhere λ is the radial distortion parameter from one of the cameras.
NOTE: This assumes that the center of distortion is the center of the image. I.e. image center = (0,0)
NOTE: This will work on homographies induced from planes or pure rotations
NOTE: Modified from original description to handle > 6 points
- Fitzgibbon, Andrew W. "Simultaneous linear estimation of multiple view geometry and lens distortion." CVPR 2001
- Kukelova, Z., Heller, J., Bujnak, M., & Pajdla, T. "Radial distortion homography" (2015)
- Peter Abeles, "Notes on Scene Reconstruction: BoofCV Technical Report", 2022
Nested Class SummaryModifier and TypeClassDescription
static classEstimated homography matrix and radial distortion terms
Method SummaryModifier and TypeMethodDescription
(List<AssociatedPair> points, HomographyRadial6Pts.Result result)Used to evaluate how good a hypothesis is by removing radial distortion from points then applying the found homography.
(List<AssociatedPair> points)Computes the homography matrix given a set of observed points in two images.
(@Nullable PrintStream out, @Nullable Set<String> configuration)
processpublic boolean process
Computes the homography matrix given a set of observed points in two images. A set ofTo get the output call
AssociatedPairis passed in. The computed homography 'H' is found such that the attributes 'p1' and 'p2' in
AssociatedPairrefers to x1 and x2, respectively, in the equation below:
x2 = H*x1
#getFound(). One way to evaluate multiple solutions to see which one is best is to call
points- A set of observed image points that are generated from a planar object. Minimum of 6 pairs required.
- True if successful. False if it failed.
computeResidualErrorpublic static double computeResidualError
(List<AssociatedPair> points, HomographyRadial6Pts.Result result)Used to evaluate how good a hypothesis is by removing radial distortion from points then applying the found homography. The difference between the observed undistorted point and the predicted point in view 2 is the computed and summed across all points.
points- Observed point pairs
- sqrt(sum residual error squared)/N
setVerbosepublic void setVerbose
(@Nullable @Nullable PrintStream out, @Nullable @Nullable Set<String> configuration)
- Specified by: