Volume 55, Number 1-2, 2014 83 Three-Dimensional Scanning and Graphic Processing System Valentin Dan ZAHARIA, Rodica HOLONEC, Septimiu CRIŞAN, Călin MUREŞAN, Radu MUNTEANU jr. Faculty of Electrical Engineering, Technical University of Cluj-Napoca 25-26, Bariţiu st., Cluj-Napoca, Romania Abstract With the recent advances in the field of three-dimensional printing systems, prototyping and manufacturing has become available on a large scale. In order to print a three-dimensional a digital model is needed, which can be obtained by designing that model in a specialized graphic programming environment, or by scanning and digitizing an existing. The letter option often involves sophisticated and costly equipment, therefore posing a challenge to the implementation of a full reproduction system. The paper introduces the design and implementation of a low-cost three-dimensional scanning and graphic processing system, presenting the hardware components as well as the software which has been developed. Some preliminary experiments have been conducted and the results have been presented. Key words three-dimensional scanning, digitization, reconstruct, laser triangulation INTRODUCTION Although three-dimensional (3D) scanning has been around for almost two decades, it still represents a quite novel measurement method, with various devices and techniques in testing and development stages, which might revolutionize the classic approach towards measurement. The 3D scanning process implies copying the digital information of a solid s geometry, which is also known as the digitization process. The digitization procedure implies the use of a contact or contactless probe in order to capture the s shape and to recreate them in a virtual environment as a dense network of points of (xyz) coordinates, as a 3D reproduction of the scanned. The geometrical data regarding the s shape is recorded as a point cloud. The data stored as a point cloud is post processed as a threedimensional polygonal mesh which can be stored in various CAD (Computer Aided Design) file types, the most common being the STL (Surface Tessellation Language) file format. [1][5] The basic structure of a three-dimensional scanning and graphic processing system consists of two main components: the hardware devices and the data acquisition and image processing. The hardware component (probes, sensors) is responsible for capturing the geometrical dimensions of the scanned, while the software component is responsible for representing the acquisitioned data in a virtual image processing environment. The resulting virtual model of the scanned can be used for further CAD, modelling or manufacturing purposes. [2] Physical Three-dimensional scanning system Hardware Fig. 1 Generic structure of a 3D scanning system There are various technologies used for implementing 3D scanning systems, each of them with particular limitations, advantages, disadvantages and costs. This paper presents a proposed design and an experimental implementation of a three-dimensional scanning and image processing system. Furthermore, the results of the scanning process of various shaped and textured s will be presented and analyzed. THE PROPOSED SYSTEM Software Digital model There are two major categories of 3D scanning systems: those based on a physical contact between the scanning probe and the scanned and the contactless systems. The latter can be divided as well into two categories [3][5]: Active scanning systems consist of a radiation source emitting towards the. The scanning process is conducted by detecting the amount of radiation reflected or absorbed by the. 2014 Mediamira Science Publisher. All rights reserved
84 ACTA ELECTROTEHNICA Passive scanning systems are based on the detection of reflected ambient radiation, mostly visible light, due to the ease of detection, the wide availability of detection devices, and the method s inherent simplicity. The proposed system presented in this paper is a contactless, active one, based on the laser triangulation technique. detects the laser point at various positions in its field. The technique is called triangulation due to the fact that the laser point on the s surface, the camera and the laser module define a triangle. The length of one of the triangle s sides (the distance between the camera and the laser module) is fixed and known. The angle between the camera s direction and the laser module s direction is also known, and so is the angle between the camera-laser line and the laser module s direction. These three pieces of information can be used to compute the triangle s dimensions and therefore to determine the laser point s position on the s surface. In addition, the position of the camera relative to the motor s spindle is known in order to help determine the angle measured on the camera. Fig. 2 The 3D laser scanner principle [4] The working principle of the triangulation system consists in a radiation being emitted towards the outer surface of the scanned and the measurement of the return angle of the emitted beam. The radiation can be of various wavelengths, belonging to different spectral domains: visible light, infrared light and ultrasonic or electromagnetic waves. The radiation reflected by the s surface is detected with a sensitive device (in the case of light, a camera is used). Then the information acquisitioned by the sensitive element is processed according to predefined algorithms in a software environment in order to digitally recreate the scanned. [6] The scanning system presented in this paper uses a laser light source which emits a radiation towards the s surface. The is placed on a turntable driven by a stepper motor at a constant speed. The light reflected by the s surface is captured by camera, which must be placed at a well-defined angle and distance from the laser s position and from the motor s spindle. The software designed for the application controls the rotation speed for the stepper motor, the laser module and it also performs the image acquisition and processing functions. The laser beam is emitted towards the scanned and depending on the s shape the camera Fig. 3 The triangulation method principle [5] If d is the known distance between the camera and the laser module, and starting from the camera parameters, the Θ angle between the laser-camera and camera-motor center can be computed, then the distance x between the laser module and the spot on the s surface is given by the following: (1) In order to speed up the scanning process, a linear laser module will be used, therefore the radiation projected on the s surface is a continuous vertical line taking the s shape as it rotates in front of the fixed light source and camera. The scanning process is finished once the completes a full rotation, after which the digitized reproduction of the scanned is available for further manipulation. The block diagram for the proposed system is presented in the following figure which gives the general structure of the implemented system that will be presented in the following section of the paper.
Volume 55, Number 1-2, 2014 85 THE EXPERIMENTAL SYSTEM As it has been mentioned before, the threedimensional scanning and graphic processing system presented in this paper consists of two main components: the hardware setup and the acquisition and processing software. The hardware elements composing the system are the stepper motor, used for rotating the turntable Fig. 4 The proposed system s block diagram upon which the scanned is placed, the linear laser module and the camera. A Funduino 2560 development board is used to command a ULN2003 motor driver which controls the stepper motor as well as the system s laser module. The microcontroller board is connected to a PC terminal which runs the system s user interface and the image acquisition and processing software. The reconstruction procedure uses a variation of the triangulation method that takes the field of the camera into account and is based on the geometrical parameters of the scanning system: the distances between the s rotation center to the camera and to the laser module, as well as the angle between the directions of the camera and of the laser module. The parameters presented above are presented in the following figure, as follows: q the distance between the laser module and the s rotation center; Fig. 5 The experimental system w the distance between the camera and the s rotation center; α the angle between the laser s direction and the camera s optical axis. In order to digitally reconstruct the, it is necessary to determine the coordinates for the scanning points, which involves determining the distance between the s rotation axis and the point projected on the s surface. It is necessary to determine the distance in pixels (b) between the camera s optical axis and the point generated on the s surface, and to convert it into millimeters. The
86 ACTA ELECTROTEHNICA angle α is a known constant, and therefore ρ can be computed with the following formulas: where ρ is computed according to (3) and (4), φ is the platform s rotation angle which is constantly increasing with each additional motor step: (2) (5) (3) Fig. 7 Polar coordinates of a projected point (P) on the s surface Converting the polar coordinates to cartesian ones is done with the following formulas: (6) (7) (8) Fig. 6 The scanning system s geometrical parameters The polar coordinates for the projected point on the s surface (P) are the following: (4) The software developed for the proposed scanning system has been implemented in the Labview programming environment. It consists of a series of subroutines responsible for coordinating the system s hardware components (microcontroller board, laser module and stepper motor), the image acquisition and processing functions, as well as the final reconstruction. The programming environment also provided resources for the development of the system s user interface, presented in the following figure: Fig. 8 The system s user interface
Volume 55, Number 1-2, 2014 87 The numbered fields on the user interface have the following functions: 1 allows the communication port between the PC and the microcontroller board; 2 a). calibration settings, b). scanning parameters (number of frames, frame rate, resolution); 3 a). source image, b). points detected from the source image; 4 start/stop buttons; 5 the digitally reconstructed 6 error indicators for each of the software s substructures. Fig.12 Transparent EXPERIMENTAL RESULTS Using the system presented above, a series of experimental trials have been conducted. Objects of various dimensions, shapes, symmetries related to the rotation axis, colors and transparencies have been scanned. Both visible (650 nm) and infrared (808 nm) light sources have been used. The scanning results are presented as follows: Fig.9 Symmetrical Fig.10 Asymmetrical Fig.11 Multicolor Fig.13 Reflecting In order to evaluate the scanning results, the following classification has been proposed. Five classes of scanning result accuracy have been defined: Table 1 Scanning result classification No. Features Dimensions Texture Color 1 2 3 4 5 6 7 8 Symmetrica l Reflecting symmetrical Slightly reflecting symmetrical Multicolor symmetrical Slightly transparent irregular Irregular Irregular Multifacete d Very smooth Very smooth Light grey Grey, green Result class 5 4 Red 4 Blue, white White 2 Slightly rough Creamcolored Light grey Transpa rent Class 5 Positive. Very good scanning results, the is completely reconstructed, with a high detail level. Class 4 Positive. Good scanning results. The is completely reconstructed, lacking high accuracy on fine details. Class 3 Positive. Acceptable results. The s physical structure is reproduced with some irregularities. 3 2 3 1
88 ACTA ELECTROTEHNICA Class 2 Negative. There are similarities between the and the reconstructed model, however the final result is not acceptable. Class 1 Negative. There is no resemblance between the and the resulted digital model. The scanning results have been appreciated in accordance with the classes described above and the conclusions have been presented in the following table. CONCLUSIONS The paper describes the working principle and implementation of a three-dimensional scanning system, based on the laser triangulation technique. Specific image acquisition and processing algorithms have been implemented in the system s software package. The presented scanning and image processing system is able to digitally reproduce s with dimensions between 5 cm and 15 cm, with various degrees of accuracy, depending on the scanned s symmetry, color, texture and transparency. The hardware components also have a major influence on the scanning and reconstruction processes results, as well as the influence of the environmental lighting. Given the above facts, the quality of the resulted digitized model can be improved with a high resolution camera, a stepper motor with higher resolution, the laser module with a thinner line and optical filters, to diminish the environmental interferences. It is the authors desire to improve the system s performances in order to integrate it with a threedimensional printing device, which will allow the physical reproduction of three-dimensional s within the specified dimensions. REFERENCES 1. Bernardini, Fausto; Rushmeier, Holly E. "The 3D Model Acquisition Pipeline" (pdf). Comput. Graph. Forum 21 (2): 149 172. doi:10.1111/1467-8659.00574, 2002 2. Chiorenu, Adrian Cosmin Cercetări privind analiza imaginilor cu aplicații în reconstrucția 3D, Universitatea Tehnică din Cluj-Napoca, 2009 3. Curless, Brian "From Range Scans to 3D Models". ACM SIGGRAPH Computer Graphics 33 (4): 38 41. doi:10.1145/345370.345399, 2000 4. Mayer, Roy Scientific Canadian: Invention and Innovation From Canada's National Research Council. Vancouver: Raincoast Books. ISBN 1-55192-266-5. OCLC 41347212, 1999 5. Voicu, Adrian-Cătălin ; Gheorghe, Gheorghe I.; Măsurarea 3D a reperelor complexe dinindustria auto utilizând scanerele laser, Buletinul AGIR nr. 3/2013 iulie-septembrie, pp:107-112 6. http://downloads.david-3d.com/sls-2/david-sls-2- Quickguide-EN_web.pdf