Aiming at a fully autonomous robotic system for endoscopic diagnosis and treatment, a method for constructing a voxel map of the internal structure of the human intestine is proposed to realize accurate estimation of the endoscope pose and construct a voxel map for the navigation of the surgical robot. A monocular endoscope is used to capture image sequences of the intestinal interior in this method. Firstly, the endoscopic trajectory is estimated based on a monocular SLAM (simultaneous localization and mapping) method and a sparse map of the internal structure of the intestinal tract is constructed. Based on the sparse feature point map, a densification solution of sparse map based on triangulation is proposed to construct a voxel map with dense geometric information for path planning of surgical instruments. In experimental study, voxel maps are constructed in the simulated intestine and the in vitro pig intestine respectively, and the error evaluation is carried out. The mean square errors of the diameter and lesion size in the simulated intestine are 1.16 mm and 0.81 mm, respectively. The mean square error of endoscopic positioning is 2.163 mm.