Skip to content

Commit 27d23f0

Browse files
committed
Add mesh API documentation to ctlgeom.h
1 parent 0c458ec commit 27d23f0

1 file changed

Lines changed: 5 additions & 2 deletions

File tree

utils/ctlgeom.h

Lines changed: 5 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -173,11 +173,14 @@ GEOMETRIC_OBJECT make_slanted_prism_with_center(MATERIAL_TYPE material, vector3
173173
const vector3 *vertices, int num_vertices, double height,
174174
vector3 axis, double sidewall_angle);
175175

176-
// mesh with center computed as centroid of vertices
176+
// Closed triangulated 3D mesh. Vertices are shared; triangles index into the
177+
// vertex array (0-based, 3 ints per triangle). A BVH is built internally for
178+
// O(log N) queries. The mesh must be watertight (every edge shared by exactly
179+
// 2 faces); open meshes are detected at init time and produce a warning.
177180
GEOMETRIC_OBJECT make_mesh(MATERIAL_TYPE material, const vector3 *vertices, int num_vertices,
178181
const int *triangles, int num_triangles);
179182

180-
// mesh with explicit center (vertices shifted so centroid = center)
183+
// As make_mesh, but translates vertices so the centroid equals center.
181184
GEOMETRIC_OBJECT make_mesh_with_center(MATERIAL_TYPE material, vector3 center,
182185
const vector3 *vertices, int num_vertices,
183186
const int *triangles, int num_triangles);

0 commit comments

Comments
 (0)