1. A projector comprising: an image taking part that takes an image of an area that includes a target onto which an image is being projected; a distance measuring part that calculates, from taken image data obtained by the image taking part, distance data concerning a distance between the target and the image taking part; a plane estimation part that estimates, from the distance data, a plane corresponding to the target; and a focusing adjustment part that adjusts focusing of the image being projected, based on information concerning the plane, wherein the distance measuring part calculates, from the taken image data, plural sets of the distance data concerning plural positions corresponding to the target, the plane estimation part removes the distance data concerning positions of the plural positions having a distance apart from the plane which is greater than a predetermined distance, the plane estimation part calculates the number of the sets of the remaining distance data having the positions that exist in a predetermined range from the center of the area, and calculates a ratio of the calculated number of the sets of the remaining distance data to the number of the plural sets of the distance data, and the plane estimation part recursively approximates the plane based on the remaining distance data when the calculated ratio is greater than a predetermined ratio.