A new kind of structured-lighting surface sensor based on computer vision is presented. The sensor can be used to complete dimensional measurements in an industrial environment with the help of smart calibration processes and image algorithms. The mathematical model and calibration techniques for the sensor are described in detail. In the local calibration, termed the differential method, structured parameters and the local coordinate system of the sensor are determined. Subsequently, a global calibration process is introduced briefly. As an application, a sample vision inspection system is built for checking dimensions on the left sideframe of a body-in-white (BIW). An automotive BIW is an assembled body before insertion of door, windshield, hood, decklid, and fender.