The optics-based systems for positioning and motion tracking in the field of teletherapy are spreading. These solutions are based on surface registration, as two or more camera frames are processed to produce a point cloud. The method is aided by structured light, which refers to a light pattern projected onto the target object. The first part of this thesis presents a quick introduction to radiotherapy, teletherapy and surface reconstruction. Details about the theoretical background of the reconstruction is provided on the topics of pinhole camera model, camera calibration, rectification and determining a virtual camera pair, correspondence search and producing point cloud from a disparity map. Additionally, a novel approach for surface reconstruction based on the Local Binary Pattern transformation is discussed. In the second part, the documentation of prototypes implemented in MATLAB and the C++ programming language can be found, as well as the evaluation of the system using synthetic and real-world data.