Research on the Optimal Slicing Algorithm of the STL Model in Additive Manufacturing
Author of the article:YI Xianjun, PENG Hongchi, LIANG Yinyi, ZHOU Rui
Author's Workplace:School of Electrical and Information Engineering, Wuhan Institute of Technology, Wuhan 430205, China
Key Words:additive manufacturing; stereo lithography model; ray-casting; depth-first search; slicing algorithm; optimization algorithm
Abstract:To improve the efficiency and the success ratio of slicing STL (stereo lithography) data model in the additive
manufacturing process, this paper has presented an optimized STL model slicing algorithm. This algorithm mainly included
three parts: layering the triangular facets, removing redundant line segments, and sorting the vertices of the outline. First, all
triangular facets were layered according to the lowest point in their slicing direction to improve slicing efficiency, which
means that only the valid data of the previous layer are inherited while switching from the previous layer to the current
layer. Then, a method based on the ray casting algorithm and multiple depth-first search (DFS) to solve the problem of
contour intersection in singular cases was presented to obtain the outermost outline vertices in the complex case of
intersection points on the outline. Finally, multiple depth-first search was used to sort the outline vertices according to the
connectivity of the final line segments formed by intersection points. The test program based on the Qt development
platform can test multiple complex STL models. The results show that the algorithm can solve the singular problem of
contour intersection in the slicing process, and can also complete the slicing work well for complex STL models containing
multiple closed holes.