| Title: | Calculate 3D Contour Meshes Using the Marching Cubes Algorithm |
|---|---|
| Description: | A port of the C++ routine for applying the marching cubes algorithm written by Thomas Lewiner et al. (2012) <doi:10.1080/10867651.2003.10487582> into an R package. The package supplies the contour3d() function, which takes a 3-dimensional array of voxel data and calculates the vertices, vertex normals, and faces for a 3d mesh representing the contour(s) at a given level. |
| Authors: | S. H. Wilks [aut, cre], Thomas Lewiner [aut] |
| Maintainer: | S. H. Wilks <[email protected]> |
| License: | MIT + file LICENSE |
| Version: | 0.1.4 |
| Built: | 2026-06-02 09:50:22 UTC |
| Source: | https://github.com/shwilks/rmarchingcubes |
Computes a 3D contours or isosurface by the marching cubes algorithm.
contour3d(griddata, level, x, y, z)contour3d(griddata, level, x, y, z)
griddata |
A three dimensional array from which to calculate the contour |
level |
The level at which to construct the contour surface |
x, y, z
|
locations of grid planes at which values in |
Returns a list with coordinates of each surface vertex, indices of the vertices that make up each triangle, and surface normals at each vertex