SAM 3D Body: Add Mesh to Skeleton
Rebuild a mesh from a saved pose without re-running detection
- skeleton
- model
- mesh_data
This node is the bridge between SAM3DBody's two parallel outputs: skeletons and meshes. SAM3DBodyProcess gives you both at once, but if you've saved just the skeleton with SAM3DBodySaveSkeleton and reloaded it later via SAM3DBodyLoadSkeleton, you don't have a mesh anymore - only pose data. SAM3DBodyAddMeshToSkeleton takes that skeleton back and regenerates a mesh for it, using the loaded model rather than re-running detection on an image.
How it works
Skeletons are lighter than full meshes - pose and joint data, not surface geometry - which is the whole reason SAM3DBodySaveSkeleton exists as a separate, smaller export. The tradeoff is that a skeleton by itself isn't visualizable or exportable as a mesh. This node closes that gap: hand it a skeleton plus the SAM 3D Body model, and it reconstructs a mesh consistent with that pose, without needing the original photo again.
The inputs and outputs that matter
skeleton(SKELETON) - required. Comes fromSAM3DBodyProcess,SAM3DBodyProcessAdvanced, orSAM3DBodyLoadSkeletonif you're reloading a saved pose.model(SAM3D_MODEL) - required, the sameLoadSAM3DBodyModelhandle you'd feed any Process node. The mesh reconstruction still needs the underlying SAM 3D Body model loaded, even though there's no image involved this time.
One output: mesh_data (SAM3D_OUTPUT) - a mesh you can treat exactly like output from any Process node: visualize it, export it as STL or rigged FBX, or inspect it with SAM3DBodyGetVertices.
How to install it
Bundled with the full pack. Via ComfyUI Manager: search SAM3DBody, install, restart. Manual install:
cd ComfyUI/custom_nodes
git clone https://github.com/PozzettiAndrea/ComfyUI-SAM3DBody.git
cd ComfyUI-SAM3DBody
pip install -r requirements.txt --upgrade
python install.py
You need LoadSAM3DBodyModel working end to end before this node is useful - including having cleared Meta's Hugging Face access gate on the checkpoint, since this node still calls into the loaded model to build the mesh.
Common issues & troubleshooting
You're not sure why you'd use this instead of just re-running the original photo through Process again. The main case: you built a pose library with SAM3DBodySaveSkeleton - maybe poses pulled from several different photos - and now want to generate a mesh for one of those saved poses without keeping every source image around, or without paying the detection/segmentation cost again. This node is the "give me a body back for this pose" step.
Resulting mesh looks generic, not like the original subject. That tracks with what a skeleton actually stores - pose and joint positions, not the specific body shape details from a particular photo. If you need the mesh to reflect one person's actual proportions precisely, keep the full mesh_data from the original Process run rather than round-tripping through a skeleton save/load.
Model input error even though you loaded it earlier in the session. Confirm the LoadSAM3DBodyModel node is still wired directly into this node's model input - it's easy to have loaded the model for an earlier Process node in the graph and forgotten to also connect it here, since this node needs its own explicit connection.
Inputs (2)
| Name | Type | Default | Description |
|---|---|---|---|
| skeleton | SKELETON | Skeleton data with pose/shape/scale parameters | |
| model | SAM3D_MODEL | Loaded SAM3D Body model (needed for MHR) |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| mesh_data | SAM3D_OUTPUT | — |