This thesis spans the development of methods for the purpose of measuring the distance and orientation of a surface through the use of laser triangulation between the pilot beam of a medical laser scanning head and an inbuilt camera. The goal is to enable automated handling of an otherwise handheld scanning head with an industrial robot arm. First, the approximate whereabouts of the pilot beam are extracted from the image, followed by precise detection of its centerline. Thusly it is possible to triangulate the coordinates of the beam-lit surface. Testing has shown the system to be capable of performing measurements with a standard deviation of the measured distance being under 2 mm, and typically under 5 degrees for the measured rotation.