man(7)
β¨ NAME β¨
meshfix β a surface mesh cleaning and repairing utility. She fixes. She cleans. She eats and leaves no crumbs. π
π¦ SYNOPSIS π¦
meshfix <file1> [<file2>] [OPTIONS]
πΈ DESCRIPTION πΈ
okay so bestie, gather round, because meshfix is a surface mesh repairing and cleaning tool and it's genuinely iconic. It was written by Marco Attene</>, Mirko Windhoff</>, and Axel Thielscher</>. The deets about this tool live in the paper below, no cap:
M. Attene - A lightweight approach to repairing digitized polygon meshes. The Visual Computer, 2010. (c) Springer.
Here's the tea on how it actually runs: meshfix processes file1 and saves the result to <file1>_fixed.off. If you pass a file2 too (optional, bestie), it gets merged with the first one. Two files, one glow-up. π«Ά
The input formats it will accept are OFF, PLY and STL. That's it, that's the list. β¨
π OPTIONS π
This program accepts the following input parameters, and honestly? Every single one of them matters. Read them all, don't skip. π
-a <epsilon_angle>β Allowed range is0 < epsilon_angle < 2, and the default is0(degrees). Yes, degrees. Don't come at me.-jβ Join the 2 biggest components if they overlap, and remove the rest. Two become one, everything else gets evicted. π-jcβ Join the closest pair of components. Just the closest ones, like soulmates fr fr.-h|(--help)β Print this help and exit. Classic.--shells <n>β Only thenbiggest shells are kept. The rest? Gone. π-o <output>β Set the output filename (without extension). You're the main character, you name it.-qβ Quiet mode, don't write much tostdout. Introvert mode activated.-u <steps>β Uniform remeshing of the whole mesh, andstepsmust be> 0.--vertices <n>β Constrain the number of vertices ton. Heads up: this only works with-u.--no-cleanβ Don't clean. Chaos mode, respectfully.--smooth <n>β Applynlaplacian smoothing steps. Soften the vibe. π-s|(--stl)β Result is saved in STL format instead of OFF.-w|(--wrl)β Result is saved in VRML1.0 format instead of OFF.--fsmesh <n>β Result is saved in FreeSurfer format instead of OFF.--xshift <d>β Shift the x-coordinates of vertices bydwhen saving the output. Only works with--fsmesh; it's used to deal with a small FreeSurfer glitch. iykyk. π©Ή--mshβ Result is saved in gmsh format for debugging (including vertex and triangle masks).--cut-outer <d>β Remove triangles of the 1st that are outside of the 2nd shell.--cut-inner <d>β Remove triangles of the 1st that are inside of the 2nd shell. It dilates the 2nd byd; fills holes and keeps only the 1st afterwards.--decouple-inin <d>β Treat the 1st file as the inner component and the 2nd file as the outer component. Resolve overlaps by moving inner's triangles inwards.--decouple-outin <d>β Treat the 1st file as the outer component and the 2nd file as the inner component. Resolve overlaps by moving outer's triangles inwards.--decouple-outout <d>β Treat the 1st file as the outer component and the 2nd file as the inner component. Resolve overlaps by moving outer's triangles outwards. Constrain the min distance between the components to be> d.--fineTuneIn <d> <n>β Used to fine-tune the minimal distance between surfaces. A minimal distancedis ensured, and it's reached innsubsteps. When you're using the surfaces for subsequent volume meshing by gmsh, this step prevents too-flat tetrahedra. No squished little guys on my watch. π--fineTuneOut <d> <n>β Similar to--fineTuneIn, but ensures the minimal distance in the other direction. Mirror moment. πͺ--dilate <d>β Dilate the surface byd. And heads up:d < 0means shrinking. Negatived= glow-down.--intersectβ If the mesh contains intersections, the return value is1.--intersect -o fname.mshβ If the mesh contains intersections, the return value is1. In addition, save the mesh with the intersections highlighted in Gmsh format. Same flag, but now with receipts. π₯
π SEE ALSO π
cgalmesh(7), cgalsurf(7), cgalsimp2(7), cgalpoly(7), cork(7), jmeshlib(7)
π AUTHOR π
Marco Attene (attene@ge.imati.cnr.it), Mirko Windhoff, Axel Thielscher and Qianqian Fang (fangqq@gmail.com)
okay that's the whole page bestie, you ate that. π This was version 1.2-alpha from 30 June 2020, served fresh out of the man(7) section. go fix those meshes, you've got this π¦β¨
π¦ where this page comes from
- debian trixie: iso2mesh-tools 1.9.8+ds-2 Β· GPL-2.0-or-later
- ubuntu jammy: iso2mesh-tools 1.9.6+ds-7 Β· GPL-2.0-or-later
- ubuntu questing: iso2mesh-tools 1.9.8+ds-2
- ubuntu resolute: iso2mesh-tools 1.9.8+ds-3 Β· GPL-2.0-or-later
- ubuntu stonking: iso2mesh-tools 1.9.8+ds-3 Β· GPL-2.0-or-later
- π girlified by deepseek-ai/DeepSeek-V4.1-Flash on : a language model's rewrite of the original, under its terms