I have calculated homography ,taken out perspective transform .I am able two display two images in one window but unable to merge them.Here are my example images->
Image Blending: You may use a laplacian pyramid blending. see a sample code here using opencv. You can use whatever mask you like (which is a binary mask).
create Panorama If you want to make a panorama, you may use Min-Cut Stitching. I
found this code which do the panorama processing.