当前位置:首页 > 过刊浏览->2022年43卷第12期
增材制造中STL模型优化切片算法研究
Research on the Optimal Slicing Algorithm of the STL Model in Additive Manufacturing
浏览(3839) 下载(6)
- DOI:
- 作者:
- 易先军,彭洪驰,梁音裔,周 锐
YI Xianjun, PENG Hongchi, LIANG Yinyi, ZHOU Rui
- 作者单位:
- 武汉工程大学 电气信息学院,湖北 武汉 430205
School of Electrical and Information Engineering, Wuhan Institute of Technology, Wuhan 430205, China
- 关键词:
- 增材制造;STL 模型;射线法;深度优先算法;切片算法;优化算法
additive manufacturing; stereo lithography model; ray-casting; depth-first search; slicing algorithm; optimization algorithm
- 摘要:
- 为了提高增材制造过程中 STL 数据模型的切片效率和成功率,提出了一种优化切片算法。 该算法主要包
括三角面片分层求交、优化相交轮廓、轮廓顶点排序 3 个部分。 首先,将所有三角面片基于其切片方向上的最低顶点进
行分层,从前一层切换到当前有效层时,继承前一层的有效数据;然后结合射线法和深度优先搜索算法解决奇异情况下
轮廓相交的问题,得到轮廓最外层顶点;最后,采用多重深度优先搜索算法,根据交点形成的线段的连通性,对轮廓顶点
进行排序。 基于 Qt 开发平台编写测试程序,对复杂 STL 模型进行切片测试。 结果表明,该算法能较好地解决切片过程
中轮廓相交的奇异问题,并且对于包含多个闭合孔洞的复杂 STL 模型也能很好地完成切片工作。
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.