MESH to Trimesh
The converter that turns the pack's bare MESH object back into a real trimesh
- mesh
- TRIMESH
MESHToTrimesh is a converter, and converters in this pack are two minutes of reading. It takes the pack's internal MESH object - the minimal torch-tensor mesh type (vertices + faces, nothing else) - and rebuilds a full TRIMESH from it, the format every real node in the wrapper actually works with.
The question it answers is "what do I do with a MESH socket?" If another node hands you a MESH output and you want to feed it into Hy3DPostprocessMesh, Hy3DRenderMultiView, the PBR nodes, or export - you run it through this node first. It's the interop bridge, the "get me back to normal" adapter, in the same direction the whole pack runs on.
How it works
One input (mesh), one output (TRIMESH). It takes the MESH's batched vertices and faces tensors, strips the batch dimension, and builds a trimesh: Trimesh.Trimesh(mesh.vertices[0], mesh.faces[0]). That's the entire mechanism - it's a data-shape conversion, no sampling, no model, no GPU, instantaneous.
There's one authorial wrinkle worth knowing so it doesn't confuse you: both directions of this pair (this node and its sibling TrimeshToMESH) carry the same copy-pasted description - "Converts trimesh object to ComfyUI MESH object, which only includes mesh data." Only one of them can be right at a time, and this one is the other direction. Trust the socket types, not the descriptions.
Where you'll hit it
Rarely, unless you're mixing packs or building custom plumbing. The wrapper's own pipeline never needs it - Hy3DGenerateMesh/Hy3DVAEDecode output TRIMESH directly. You'd reach for it when:
- a node from another pack hands you a
MESHsocket and you need aTRIMESH; - you're writing custom nodes against this pack's types and round-tripping data.
Install
Pack-level: Manager search "Hunyuan3DWrapper", or git clone https://github.com/kijai/ComfyUI-Hunyuan3DWrapper, then pip install -r requirements.txt. Trivial node, trivial deps - nothing else required.
Common issues
- Output has no texture/UVs - by design. The
MESHtype carries geometry only; you're not losing data that was there, because the source never had it. If you need materials back, keep aTRIMESHaround rather than round-tripping. - "Wrong socket" when wiring - a
MESHoutput from a different pack may not be this pack'sMESHtype. ComfyUI types are pack-local; if it won't connect, it isn't the same type no matter how the name looks.
Inputs (1)
| Name | Type | Default | Description |
|---|---|---|---|
| mesh | MESH | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| TRIMESH | TRIMESH | TRIMESH object containing vertices and faces as torch tensors. |