Skip to content →

/hɒˈmɒɡ.rə.fi/

Homography

noun · computer vision

A projective transformation that maps the points of one flat plane onto another. In augmented reality it lets an app keep a reference image pinned flat on a real surface, such as paper, as the camera angle and position change.

What it is

When you photograph a rectangular sheet of paper from an angle, the rectangle looks like a slanted four-sided shape rather than a clean rectangle. A homography is the mathematical rule that describes exactly how the true flat rectangle maps to that skewed on-screen shape. Because the relationship works both ways, the same rule can take a reference image and warp it so it appears to lie flat on the paper — no matter how the camera is tilted.

This is the quiet piece of maths behind a steady AR tracing overlay. As you move the phone, the app recalculates the homography many times a second, keeping the reference image "stuck" to the sheet rather than sliding around. A homography only holds for flat surfaces, which is why apps first use plane tracking to find the plane before locking the image onto it. It is one thread of the wider augmented reality stack.

Diagram of a square mapped by a homography into a skewed quadrilateral
A homography maps a flat square (left) to the skewed shape a tilted camera sees (right), and back again.

Etymology

The word joins the Greek homos, "same," with graphein, "to draw" — loosely, "drawing the same thing" in a different frame. The mathematical concept comes from projective geometry, developed in the nineteenth century, long before computers. It became a workhorse of computer vision once cameras and processors could apply it in real time; standard references such as Hartley and Zisserman's textbook treat the planar homography as a core tool.1

Examples in use

A document-scanner app uses a homography to "flatten" a photo of a page taken at an angle back into a clean rectangle. A sports broadcast uses one to paint a virtual first-down line flat on the pitch. In drawing, the homography is what keeps a reference lined up on your paper during AR tracing. None of this touches the free web tool, which draws overlays in the browser with no camera and no tracking.

References

  1. Hartley, Richard, and Andrew Zisserman. Multiple View Geometry in Computer Vision. 2nd ed. Cambridge University Press, 2004. ISBN 978-0-521-54051-3.
  2. Azuma, Ronald T. "A Survey of Augmented Reality." Presence: Teleoperators and Virtual Environments 6, no. 4 (1997): 355–385. DOI: 10.1162/pres.1997.6.4.355.