# Surface meshes

A surface mesh is a data object representing a closed, orientable two-dimensional manifold. Surface meshes in OVITO are typically generated using modifiers such as:

- Construct surface mesh – Constructs a closed surface around a set of particles.

- Create isosurface – Generates an isosurface from scalar field data.

- Voronoi analysis – Computes the Voronoi tessellation of a particle system.

- Coordination polyhedra – Creates polyhedral representations based on particle coordination.

The appearance of a surface mesh is controlled by a corresponding Surface mesh visual element, which is found under the Visual elements section of the pipeline editor.

## Periodic surfaces

Surface meshes can exist within a periodic simulation domain, meaning their triangle faces may wrap around and connect vertices on opposite sides of a periodic simulation cell. OVITO automatically handles these periodic intersections, ensuring a correct non-periodic representation of the triangle mesh for rendering.

See also Periodic systems and cap polygons for more information on this topic.

## Interior and exterior region

Since surface meshes are closed orientable manifolds, they define several spatial regions: one or more interior regions and an exterior region.

- When a surface mesh is generated using the Construct surface mesh modifier, the enclosed volume represents the interior region filled with particles, while the exterior is the empty space (including pores).

- There may be no interior region at all, meaning the exterior region is space-filling, resulting in a degenerate mesh with zero faces.

- The opposite can occur as well (only in periodic domains): the interior region may extend over the entire periodic domain, leaving no exterior region. Again, this results in a degenerate surface mesh with zero faces.

See also

Identification of volumetric regions

## Exporting to a file

OVITO can export surface meshes as triangle meshes in a non-periodic form. During export:

- Triangles intersecting periodic domain boundaries are truncated.

- Cap polygons are generated to fill any gaps at the periodic boundary intersections.

To export a surface mesh, use OVITO’s file export function and select the VTK format.

See also

- Output file formats

- Surface mesh file writer (code example)

- `ovito.data.SurfaceMesh` (Python API)