write_mesh#
- brainglobe_atlasapi.atlas_generation.mesh_utils.write_mesh(mesh: Mesh, mesh_dir: Path, segment_id: int, vertex_quantization_bits: int = 16, compression_level: int = 0)[source]#
Write one object as a single-LOD, single-fragment multi-res mesh.
- Parameters:
mesh_dir (path to the mesh directory (gets info, <id>, <id>.index))
segment_id (int label of the object)
vertices ((N, 3) float array of xyz coordinates ("points"))
faces ((M, 3) int array of triangle vertex indices)
vertex_quantization_bits (10 or 16 (Neuroglancer only allows these two))
compression_level (0-10 (higher = more compression))