1. An image processing device used for a projector adapted to display an image formed from image data by projecting the image on a projection surface comprising: a detection image generation section adapted to generate a detection image which is different from the image formed from the image data, the detection image being an image adapted to detect a state of a projection image displayed on the projection surface, the detection image including a plurality of detection image parts, and the projection image being an image obtained by superimposing the detection image on the image formed from the image data, wherein each of the detection image parts includes a plurality of regions having respective luminance values different from each other, and the detection image generation section changes a luminance distribution of each of the detection image parts of the detection image to be generated so that maximum luminance values of the detection image parts included in a taken detection image obtained by taking the detection image projected on the projection surface fall within an allowable range.