I used one architecture photo I took in Mexico City as an example of rectification. I defined correspondence points from the pillars and windows of the front side of the building, which I know that they should be parallel and in rectangles. Then I computed a homography matrix H using least-squares and warped the original image to the homography to get the rectified image. The result image has a frontal-parallel plane of the front side of the building.
Mexican Architecture |
Rectified Mexican Architecture |