if the heights of the two images are h1 and h2