A first image of the eye is generated when the cornea of the eye is exposed to a gas. The cornea is covered with an optic of a patient interface. A second image of the eye with the patient interface over the cornea is generated. In this second image, the patient interface distorts the second image of the eye. One or more of a position or an orientation of the eye is determined in response to the first image and the second image when the patient interface has been placed over the cornea.