A calibrated camera can estimate a ground plane from a single image when you know where measured points lie on that plane. Four corners of a measured square are enough to establish the mapping, but they do not automatically establish that the result is accurate.
This workflow is for locating a stationary work plane, measuring positions on a flat surface, or establishing a reference frame. You will define the plane coordinates, correct the image geometry, estimate its pose, and verify the answer independently. The key distinction is between mapping image pixels onto a plane and recovering that plane's orientation and position relative to the camera.
What four points can and cannot recover
Four corresponding points determine a planar homography when no three are collinear and the configuration is not degenerate. Each point contributes two independent equations. A homography has eight independent parameters because its overall scale does not affect the mapping.
A homography relates two-dimensional coordinates on the plane to two-dimensional image coordinates. That does not make it unrelated to three-dimensional pose: with calibrated camera intrinsics, its columns contain the plane's rotation and translation information.
| Available information | What you can recover | What remains uncertain |
|---|---|---|
| Four valid correspondences with measured plane coordinates | Image-to-plane mapping | Physical pose without camera calibration |
| The mapping plus calibrated intrinsics | Plane rotation and translation | Reliability under image noise and calibration error |
| A square with an unknown physical side length | Pose expressed in square-side units | Absolute metric scale |
| An arbitrary quadrilateral that only looks square | A mathematical mapping to a chosen square | Whether the assumed geometry matches reality |
The reconstruction describes the selected plane, not every object in the scene. A feature above that plane will generally be assigned the wrong ground position if you map it through the same homography.
If you still need reliable camera parameters, start with calibrating a single camera. Field of view alone does not provide a complete distortion model or independently establish every intrinsic parameter.
1. Define measured plane coordinates
- Choose a physical origin on the plane, preferably a clearly identifiable corner.
- Define the positive horizontal axes and the plane normal using a right-handed coordinate system.
- Measure the square side length, or use the actual measured coordinates if the feature is rectangular.
- Record image correspondences in exactly the same order as the object coordinates.
For a square with a measured side length of 400 mm, you could define:
All points have a plane-coordinate height of zero. Their horizontal coordinates supply the metric information; the camera does not discover that scale independently.
Use a consistent clockwise or counterclockwise corner sequence without crossing the square. Mark the origin physically if the square could be mistaken for another orientation. A symmetric, unmarked square does not identify which corner you intend as the origin.
Do not replace a measured rectangle with an assumed square. Likewise, four corners on a warped sheet do not become coplanar because the software accepts them. The guide to calibration target flatness explains why physical geometry can dominate an otherwise tidy numerical fit.
2. Match image points to the calibration
Your image points, intrinsic matrix and distortion model must describe the same image geometry. Choose one processing route and keep it consistent.
- Original image coordinates: provide the original pixel points, their matching intrinsic matrix and distortion coefficients to a solver that supports distortion.
- Undistorted pixel coordinates: correct the points or image, then use the intrinsic matrix associated with that corrected output and no additional distortion correction.
- Normalized coordinates: correct the points into normalized camera coordinates, then use an identity intrinsic matrix for the corresponding geometry.
Do not undistort points and then apply the distortion coefficients again. Also, do not use the original intrinsic matrix automatically after changing the corrected image's projection or crop. The rectified-image pose estimation guide covers this distinction.
Check image dimensions, cropping, resizing and orientation against the calibration record. A resized image requires appropriately transformed intrinsics. A crop shifts the principal point. A mirrored image needs explicit handling rather than a hopeful change to point order.
For the homography equations below, use undistorted pixel coordinates and their matching intrinsic matrix. Lens distortion is not generally represented by a single planar homography across the image.
3. Estimate the plane-to-image homography
For points on the plane, write the mapping in this direction:
Here, X and Y are measured plane coordinates, u and v are undistorted pixel coordinates, and K is the matching intrinsic matrix. The vectors r1 and r2 are the first two columns of the plane-to-camera rotation. The vector t is the plane origin expressed in camera coordinates.
Use a numerically normalized homography estimator rather than building an unscaled linear system directly from large pixel and physical coordinates. If your software returns an image-to-plane mapping instead, invert it before applying this decomposition.
Four points provide a minimal fit, not redundancy. An outlier-rejection method cannot reliably identify a bad correspondence from only the minimal set. When practical, collect additional measured coplanar points and fit them together.
To map an image point back onto the plane, apply the inverse homography and divide by the final homogeneous coordinate:
This is useful without explicitly recovering pose when your only requirement is a plane-coordinate position. Recover pose when you need the normal, camera location, or a relationship to another coordinate frame.
4. Recover and refine the plane pose
Remove the camera intrinsics from the homography:
The averaged normalization is an initialization for noisy measurements. In ideal data, the first two scaled columns have unit length and are perpendicular.
Choose the homography sign so that the observed plane points lie in front of the camera. Recompute the cross-product column consistently after choosing that sign. Then project the initial rotation onto a proper rotation matrix:
The middle expression denotes a singular-value decomposition. The determinant correction prevents the result from becoming a reflection.
Finally, refine rotation and translation by minimizing reprojection error with the correct camera model. A calibrated planar pose solver can perform the initialization and refinement directly; explicit decomposition remains useful for understanding and checking its output.
Ask a planar solver for all supported pose candidates rather than accepting its first answer automatically. Noisy planar observations, particularly with weak perspective cues, can produce competing solutions with similar image errors. Positive depth rejects impossible candidates, but it does not guarantee a unique, reliable answer.
5. Check scale and coordinate direction with a worked example
Consider an ideal front-facing square with a side length of 400 mm. Assume focal lengths of 1,000 pixels and a principal point at pixel coordinates (640, 480).
Suppose its corners appear at:
The square spans 200 pixels horizontally. For this front-facing configuration only, its depth follows directly:
The corresponding plane-to-image homography, with plane coordinates entered in millimeters, is:
Removing the intrinsics gives first-column and second-column norms of 0.0005, so the normalization factor is 2000. The recovered pose is an identity rotation and a translation of (0, 0, 2000) mm under the stated axes.
Entering a side length of 1 instead would produce a depth of 5 square-side units. The image is unchanged; only the coordinate scale changes. Multiplying by the measured side length restores metric units.
Keep the transform direction explicit:
For a unit normal, the perpendicular camera-to-plane distance is abs(d). It is not generally the length of t, which measures distance to the chosen plane origin.
6. Reject plausible but incorrect solutions
Validate more than the fitted corners. Four correctly ordered points can define a homography that maps those same points almost perfectly, even when the physical assumptions are wrong.
Use the following tests in order:
- Check correspondence and units. Overlay corner identifiers and verify the physical sequence. Confirm that all dimensions use one unit system.
- Check geometry. Confirm positive depth for every observed point and a proper rotation with determinant near positive one.
- Compare candidate poses. Evaluate each using the same image coordinates and camera model. Consider which candidates satisfy known installation constraints.
- Measure held-out points. Use independently measured coplanar features that were not used in fitting. Include positions near and far from the selected square.
- Perturb the measurements. Repeat the solve after plausible corner changes, such as 0.5 pixel. Record variation in normal direction, plane distance and mapped positions.
For raw-image validation, forward-project with distortion. For undistorted-image validation, use the matching corrected projection without adding distortion again. Mixing these domains makes residuals misleading.
A nearly edge-on plane compresses one dimension and makes the calculation sensitive to small pixel errors. A small, distant square provides weak orientation information. A nearly front-facing square can also leave competing tilt estimates difficult to distinguish under noise.
The closest follow-on guide, checking extrinsic calibration beyond reprojection error, explains how independent physical measurements reveal errors that a fitting residual can miss.
7. Choose capture hardware for repeatable measurements
Select area scan cameras around the stationary feature size, required sampling and image stability. Use the camera finder to narrow the acquisition options. For a stationary target and camera, a rolling shutter can be suitable; relative motion during readout requires additional care.
The LS-CMR-0053 is a rolling-shutter GigE camera with a C-mount. Treat it as a candidate for a stationary setup, not as a guarantee of pose accuracy.
- Sensor format
- 1/1.7"
- Lens mount
- C-mount
- Interface
- GigE
- Resolution
- 12 MP
Choose machine vision lenses for coverage, working distance and corner sharpness. The lens finder helps narrow the optical choices. The LS-FFL-0602 is a C-mount lens specified for a 1-inch sensor format. Verify actual coverage and mechanical suitability for the selected camera before ordering.
- Type
- Machine vision fixed
- Sensor format
- 1"
- Mount
- C-mount
- Resolution
- 6-10 MP
Frame the measured square generously without placing its critical corners at poorly resolved image edges. Leave room for held-out validation features as well as the fitting points.
As a sampling example, a front-facing field width of 600 mm across 3,000 pixels gives:
This is an ideal local sampling estimate, not a total pose-accuracy prediction. On a tilted plane, object-space sampling varies with position. Calibration, corner localization and physical measurements add further uncertainty.
Lock focus and any adjustable optics before calibration. Keep exposure and illumination stable enough that the selected corner means the same physical location in every image.
8. Verify the result before deployment
Save the image, point order, physical dimensions, intrinsics, distortion model and transform convention alongside the estimated pose. Without those records, reproducing a successful result becomes unnecessarily difficult.
Use this acceptance checklist:
- Known geometry: the square or rectangle has measured dimensions and lies on the intended plane.
- Matching calibration: image size, crop, orientation and optical settings match the camera model.
- Independent checks: held-out positions meet the application's physical tolerance across the usable area.
- Stable solution: plausible point-localization changes do not produce unacceptable position or normal changes.
- Explicit direction: every exported transform states its source frame, destination frame and distance units.
- Valid operating conditions: camera or plane movement triggers a new pose estimate rather than silently reusing an old one.
Do not use a single-plane mapping for elevated features, warped surfaces or an unmeasured quadrilateral. Use additional geometry, multiple views or depth sensing when the task requires actual three-dimensional structure. This estimate is not a safety-rated measurement or protective function.
Start a compatible acquisition setup with the camera configurator, or contact the applications team with your plane dimensions, working distance, images and allowable position error.
Questions
Are four points enough to estimate a ground plane?
Yes, provided their physical coordinates are known, they lie on the same plane, and their arrangement is not degenerate. Four correspondences are the mathematical minimum for a homography. Additional measured points provide redundancy and help expose picking errors, inaccurate dimensions and departures from a flat surface.
Do I need camera calibration if I already have a homography?
You can calculate an image-to-plane mapping from measured coplanar correspondences without recovering a physical camera pose. Determining the plane's orientation and translation relative to the camera additionally requires an appropriate intrinsic model. Distortion must also be handled consistently, especially when the selected points cover a wide image region.
Where does metric scale come from in a single image?
The physical dimensions assigned to the reference geometry set the translation units. If you define a square as one unit wide without knowing its measured width, distances remain relative to that square. A known side length or another independent distance is needed to express the result in millimeters.
Why can a low reprojection error still give the wrong plane pose?
Small image errors can correspond to noticeably different plane tilts when perspective information is weak. Incorrect point ordering or mismatched image calibration can also produce a plausible fit. Compare candidate poses, check physical constraints, and test separate measured features instead of accepting the lowest corner residual alone.
Can the same homography locate objects above the ground?
An inverse homography places each image location at the intersection of its viewing ray with the reference plane. It does not measure the feature's actual height. Raised parts therefore need a suitable height model, additional views or depth measurements when their true three-dimensional position matters.

