A projector comprising: a projection part configured to project a predetermined pattern comprising a plurality of feature points onto a projection target (Scr); an image taking part configured to take an image of an area that includes said projection target (Scr), wherein the image taking part comprises a stereo camera (131; 131A, 131B); a distance measuring part configured to calculate, from taken image data obtained by the image taking part, a plurality of distances between the image taking part and a plurality of corresponding points extracted from said feature points, thereby providing a group of three-dimensional points; a plane estimation part configured to estimate, from the group of three-dimensional points, an equation of a regression plane corresponding to the projection target (Scr); and a focusing adjustment part configured to adjust focusing of the image being projected, based on the equation of the regression plane corresponding to the projection target (Scr); wherein the distance measuring part is configured to extract the plurality of corresponding points based on two sets of taken image data taken by the stereo camera (131; 131A, 131B) and to calculate the plurality of distances between the image taking part and the plurality of corresponding points by triangulation, and wherein the plane estimation part is configured to remove three-dimensional points at a distance from the regression plane greater than a predetermined distance, characterized in that the plane estimation part is further configured: to repeat the estimation of the equation of the regression plane without the removed three-dimensional points in order to estimate the equation of the regression plane corresponding to the projection target (Scr) in a recursive manner, to calculate the number of three-dimensional points that exist in a predetermined range from the center of the taken image area, to calculate a ratio of the calculated number to the number of three-dimensional points in the entirety of the taken image data, and to recursively estimate the equation of the regression plane only from the removed three-dimensional points in a case where the calculated ratio is less than or equal to a predetermined ratio. a projection part configured to project a predetermined pattern comprising a plurality of feature points onto a projection target (Scr); an image taking part configured to take an image of an area that includes said projection target (Scr), wherein the image taking part comprises a stereo camera (131; 131A, 131B); a distance measuring part configured to calculate, from taken image data obtained by the image taking part, a plurality of distances between the image taking part and a plurality of corresponding points extracted from said feature points, thereby providing a group of three-dimensional points; a plane estimation part configured to estimate, from the group of three-dimensional points, an equation of a regression plane corresponding to the projection target (Scr); and a focusing adjustment part configured to adjust focusing of the image being projected, based on the equation of the regression plane corresponding to the projection target (Scr); wherein the distance measuring part is configured to extract the plurality of corresponding points based on two sets of taken image data taken by the stereo camera (131; 131A, 131B) and to calculate the plurality of distances between the image taking part and the plurality of corresponding points by triangulation, and wherein the plane estimation part is configured to remove three-dimensional points at a distance from the regression plane greater than a predetermined distance, characterized in that the plane estimation part is further configured: to repeat the estimation of the equation of the regression plane without the removed three-dimensional points in order to estimate the equation of the regression plane corresponding to the projection target (Scr) in a recursive manner, to calculate the number of three-dimensional points that exist in a predetermined range from the center of the taken image area, to calculate a ratio of the calculated number to the number of three-dimensional points in the entirety of the taken image data, and to recursively estimate the equation of the regression plane only from the removed three-dimensional points in a case where the calculated ratio is less than or equal to a predetermined ratio.