extracting panorama layout