1. An imaging device comprising: an imaging lens; an image sensor that includes a photodetector cell array in which a plurality of photodetector cells are disposed in an array; a lens array for generating disparity images that is provided between the imaging lens and the image sensor, and includes a plurality of lenses that are disposed in an array; and a processor comprising hardware, wherein the processor acquires rotation information that represents a relative direction of an image of an object formed by the imaging lens and the image sensor, and generates disparity images based on the acquired rotation information and image information obtained from the image sensor.