Based on the characteristics of Laser Metal Deposition Shaping (LMDS) technology, the related data processing algorithm was investigated in detail. This paper provides a kind of layered processing algorithm for STL file based on the limited topological information. At first, the triangle facets intersected with certain layered plane in the STL file were found out in disordered state, and then were read into the memory; secondly, the topological information was built to the found triangle facets; next, the intersecting lines between the layered plane and the triangle facets were figured out, so the contour lines on the layered plane were generated according to the founded topological sorting. Over and over, this process was finished until all layered contours were worked out. This algorithm could process the large STL files, save the memory expense, and improve the computing speed.