The objective of the present invention is to obtain accurately a three-dimensional relative positional relationship between the position of the optical axis of an elongated instrument such as a rigid endoscope and a position and attitude detecting marker, using an optical axis position measuring device that is lightweight, has a simple construction, and has excellent operability and convenience. An optical axis position measuring device 80 includes: a target image of which an image can be captured by a rigid endoscope 11 and optical axis position measuring markers 91 that can be measured in three dimensions. A calculating means: stores in advance a three-dimensional relative positional relationship between the target image and the optical axis position measuring markers 91 processes three-dimensional data obtained by three-dimensional shape measurement, to acquire a three-dimensional relative positional relationship between a distal end portion 14 of the rigid endoscope 11 and a marker sphere 12, and a three-dimensional relative positional relationship between the marker sphere 12 and the optical axis position measuring markers 91 and acquires from the target image of which an image has been captured by the rigid endoscope 11, a point on the target image corresponding to the position of the center of the captured image. The calculating means obtains a three-dimensional relative positional relationship between the optical axis of the rigid endoscope 11 and the marker sphere 12 on the basis of the stored data and the acquired data.La présente invention vise à obtenir précisément une relation de position relative tridimensionnelle entre la position de laxe optique dun instrument allongé tel quun endoscope rigide et un marqueur de détection de position et dattitude, à laide dun dispositif de mesure de position daxe optique qui est léger, a une construction simple, et présente une excellente opérabilité et une excellente commodité. Un dispositif de mesure de position dax