CS 194-26 Project 4

Recovering Homographies

To find the homography matrix, we have: [wx', wy', w] = [[a,b,c], [d,e,f], [g,h,1]] [x, y, 1]
Which gives us the equations:
ax + by + c = wx'
dx + ey + f = wy'
gx + hy + 1 = w
Since this is a projective transformation and there are 8 unknowns, we need 4 points to create the 8 equations. Solve for the homographic matrix using least squares regression.

Warping the Images

Apply homography to the first image to warp to the coordinates of the second image.

Warped Image1

Image Rectification

Check if homography calculations are correct by rectifying images. The Normandy Village building is rectified so that the top-right window is frontal-parallel. The Reading Room image is rectified so that the left windows should be frontal parallel (I think my coordinate calculations were a bit off for this one).

Blend the Images into a Mosaic

Source Images

Warped Images

Resulting Mosaic