A method of generating a three-dimensional virtual model of an intraoral object includes capturing, by an imaging apparatus for performing intraoral scans, surface scan data of the intraoral object while changing a position of at least one lens of focusing optics of the imaging apparatus, wherein the surface scan data comprises depth data for a plurality of points of the intraoral object. The method further includes adjusting the depth data for one or more of the plurality of points based at least in part on the position of the at least one lens associated with the depth data for the one or more of the plurality of points. The method further includes generating the three-dimensional virtual model of the intraoral object using the adjusted depth data.