.stl - Stereolithography file format


Return to TetGen file formats page.
Return to TetGen home page.

The .stl or stereolithography format is an ASCII or binary file used in manufacturing. It is a list of the triangular surfaces that describe a computer generated solid model. This is the standard input for most rapid prototyping machines.

The description of .stl file format can be easily found elsewhere in the internet. An elaborated description can be found at here. Below is an example of this file format.

 solid
 ...
 facet normal 0.00 0.00 1.00
    outer loop
      vertex  2.00  2.00  0.00
      vertex -1.00  1.00  0.00
      vertex  0.00 -1.00  0.00
    endloop
  endfacet
 ...
 endsolid

Here is an example of using TetGen to read (-p) a polyhedron described in .stl file format (sphere.stl), compute its constrained Delaunay tetrahedralization.

tetgen -p sphere.stl
The picture of the sphere.

Source file: sphere.stl


Return to TetGen file formats page.
Return to TetGen home page.
Hang Si