Fill Holes PyMeshLab (backend)
MeshLab's hole filler, wrapped for ComfyUI
- mesh
- filled_mesh
- info
PyMeshLab is the Python side of MeshLab, the long-running open-source mesh processing workhorse, and this node is its close_holes filter packaged as a ComfyUI node. It's the hidden backend behind the pymeshlab option in the pack's Fill Holes front node, and it's a solid middle ground: more shape-aware than trimesh's naive fan fill, less finicky than the CGAL backend, and one of the most battle-tested hole closers in existence. If you've used MeshLab before, this feels like coming home.
How it works
It hands your mesh to PyMeshLab, runs close_holes, and hands the result back. The only real control is maxholesize (0–100000, default 0): the maximum number of boundary edges a hole can have and still get closed. Zero means "close everything, no matter how big." That single number is surprisingly expressive - it's the difference between patching pinholes and accidentally capping a canyon.
Outputs are filled_mesh (TRIMESH) and info, which reports faces added and whether the result is watertight. Same shape as the trimesh backend, so the two are drop-in comparable - which is the point: you can swap backends in the front node without touching the rest of the workflow.
When to pick it
The fill hierarchy in this pack goes: trimesh (fast, crude) → pymeshlab (solid default) → pymeshfix/MeshFix (refined, careful). PyMeshLab sits in the sweet spot for most scan repair - better boundary handling than trimesh on irregular holes, without the extra machinery of the dedicated fixers. Use the front node's quality: fair option with it when the holes are on curved surfaces and you want the patch to flow with the surrounding shape rather than sit flat.
Installing it
cd ComfyUI/custom_nodes
git clone https://github.com/PozzettiAndrea/ComfyUI-GeometryPack.git
cd ComfyUI-GeometryPack
pip install -r requirements.txt --upgrade
python install.py
Or ComfyUI Manager → GeometryPack → Install, restart. PyMeshLab is a main-env dependency the pack pulls in; on Linux it's part of the conda-forge environment, so make sure the pack's install actually completed before you expect this backend to show up.
Where people get burned
The same trap as its sibling: maxholesize: 0 fills absolutely everything, and a hidden giant hole becomes a giant flat patch. Cap it and walk the value up. And if the backend is missing entirely from the front node's dropdown, the PyMeshLab environment didn't build - check the ComfyUI console for the pack's "skipping" warnings at startup. This is a young, fast-moving pack; when a saved workflow throws a combo-value validation error, re-pick the backend and re-save before debugging anything else.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| mesh | TRIMESH | — | |
| maxholesizeopt | INT | 00–100000 | Max number of boundary edges composing a hole. Only holes with this many edges or fewer are closed. 0 = close all. |
Outputs (2)
| Name | Type | Description |
|---|---|---|
| filled_mesh | TRIMESH | — |
| info | STRING | — |