In this research, a revised similar triangle algorithm based upon the pinhole imaging principle is proposed to conduct a 3D optical measurement system with a vertical moving camera, The algorithm can be applied to obtain 3D-information by using simple linear relationships, in the beginging ,the measurement results can’t achieve the desired value of z coordinate values. By using the tiangle algorithm , the relationship of the height of the object can be infered. This study focus on the datas which is collected from the position on the target that we interest in, at the mean time, the accuracy can be improved by using these datas to find the main factor that effecting the measuring result.