Other supported file formats


Return to TetGen file formats page.
Return to TetGen home page.
In stead of reading and writting meshes in TetGen's own file formats, TetGen also supports other popular polyhedral and mesh file formats, such as OFF (Object File Format), PLY (Polygon File Format), and so on. This feature lets a large amount of free 3D models decribed in these file formats directly available for TetGen.

Currently, TetGen can directly read and write data in the following file formats:

TetView can visualize objects described in the above file formats. Both TetGen and TetView use the file extensions (.off, .ply, etc) to identify these different file formats.

.off - Geomview's polyhedral file formats

.off is the one of the popular file formats of Geomview - an interactive 3D viewing program for Unix/Linux. It represents collections of planar polygons with possibly shared vertices, a convenient way to describe polyhedra. The polygons may be concave but there's no provision for polygons containing holes. This file format is described in Geomview manual - OFF.

Here is an example of using TetGen to read (-p) a polyhedron described in .off file format (socket.off), compute its constrained Delaunay tetrahedralization and output (-O) the CDT in .off file format (socket.1.off).

tetgen -pO socket.off
The picture of the socket.

A big repository of free 3D models in OFF file format are available at The Princeton Shape Benchmark. Please note, these models may not be piecewise linear complexes. You can check them with the -d switch of TetGen.

.mesh - Medit's mesh file formats

.mesh is the file formats of Medit - an interactive 3D mesh viewing program. This file format is described in the documentation of Medit.

Here is an example of using TetGen to read (-p) a surface mesh described in .mesh file format, compute its constrained Delaunay tetrahedralization and output (-g) the CDT in .mesh file format.

tetgen -pg input_file.mesh
A repository of free 3D models in .mesh file format are available at INRIA's Free 3D Meshes Download.

.ply - plyhedral file format

The .ply file format is a simple object description that was designed as a convenient format for researchers who work with polygonal models. Early versions of this file format were used at Stanford University and at UNC Chapel Hill.

A description as well as examples, codes of the PLY file format can be found at this link.

Some free 3D models described in PLY file format can be found at here (many thanks Edward Verbree at TU Delft for this link).


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