A vision measuring device comprising an imaging device, the vision measuring device being adapted for measuring a workpiece by imaging said workpiece by said imaging device, wherein: said imaging device of which frame rate is variable is arranged to output an image and a time stamp corresponding to the image through a USB interface, Gig-E or Firewire and to output a vertical synchronization signal through a dedicated Digital Input/Output said vision measuring device further comprising: an illumination device adapted for irradiating the workpiece with light; a position control system arranged to control an in-focus position of the imaging device, and to acquire the in-focus position of the imaging device from a linear encoder in response to the vertical synchronization signal, and to output the in-focus position and a time stamp corresponding to the in-focus position as information representing a position in an in-focus axis direction; the vision measuring device being arranged to perform: a normal measurement in which the imaging device images the workpiece with a frame rate and the illumination device irradiates the workpiece; and an auto-focusing process comprising acquiring the in-focus position at which an image with the highest contrast is acquired, the vision measuring device comprising a control device arranged to control, when the auto-focusing is performed, a frame rate of the imaging device, and also to control at least one of the imaging device and the illumination device such that an amount of light to be received by the imaging device becomes substantially constant, and said control device being arranged to calculate a relationship between the image and the in-focus position based on their time stamps. said imaging device of which frame rate is variable is arranged to output an image and a time stamp corresponding to the image through a USB interface, Gig-E or Firewire and to output a vertical synchronization signal through a dedicated Digital Input/Output said vision measuring device further comprising: an illumination device adapted for irradiating the workpiece with light; a position control system arranged to control an in-focus position of the imaging device, and to acquire the in-focus position of the imaging device from a linear encoder in response to the vertical synchronization signal, and to output the in-focus position and a time stamp corresponding to the in-focus position as information representing a position in an in-focus axis direction; the vision measuring device being arranged to perform: a normal measurement in which the imaging device images the workpiece with a frame rate and the illumination device irradiates the workpiece; and an auto-focusing process comprising acquiring the in-focus position at which an image with the highest contrast is acquired, the vision measuring device comprising a control device arranged to control, when the auto-focusing is performed, a frame rate of the imaging device, and also to control at least one of the imaging device and the illumination device such that an amount of light to be received by the imaging device becomes substantially constant, and said control device being arranged to calculate a relationship between the image and the in-focus position based on their time stamps. an illumination device adapted for irradiating the workpiece with light; a position control system arranged to control an in-focus position of the imaging device, and to acquire the in-focus position of the imaging device from a linear encoder in response to the vertical synchronization signal, and to output the in-focus position and a time stamp corresponding to the in-focus position as information representing a position in an in-focus axis direction; the vision measuring device being arranged to perform: a normal measurement in which the imaging device images the workpiece with a frame rate and the illumination device irradiates the workpiece; and an auto-focusing process comprising acquiring the in-focus position at which an image with the highest contrast is acquired, the vision measuring device comprising a control device arranged to control, when the auto-focusing is performed, a frame rate of the imaging device, and also to control at least one of the imaging device and the illumination device such that an amount of light to be received by the imaging device becomes substantially constant, and said control device being arranged to calculate a relationship between the image and the in-focus position based on their time stamps. a normal measurement in which the imaging device images the workpiece with a frame rate and the illumination device irradiates the workpiece; and an auto-focusing process comprising acquiring the in-focus position at which an image with the highest contrast is acquired, the vision measuring device comprising a control device arranged to control, when the auto-focusing is performed, a frame rate of the imaging device, and also to control at least one of the imaging device and the illumination device such that an amount of light to be received by the imaging device becomes substantially constant, and said control device being arranged to calculate a relationship between the image and the in-focus position based on their time stamps.