Relating object and image distances