Nodes/Avatar Graph/Object Data Transfer
ComfyUI Node

Object Data Transfer

Carrying UVs and weights across rebuilt meshes in Avatar Graph

By avatechai·Created 3 years ago·Updated 2 years ago· 264
Object Data Transfer
  • BPY_OBJ
  • BPY_OBJ
use_reverse_transferfalse
use_freezefalse
data_type
use_createtrue
vert_mapping
edge_mapping
loop_mapping
poly_mapping
use_auto_transformfalse
use_object_transformtrue
use_max_distancefalse
max_distance1.00
ray_radius0.00
islands_precision0.10
layers_select_src
layers_select_dst
mix_mode
mix_factor1.00

Rebuilding a mesh - a voxel remesh, a quadriflow remesh, swapping in a cleaner version - usually means losing whatever was attached to the old topology: vertex weights, UV layouts, vertex colors, sharp-edge markings. Object Data Transfer is how you get that data back onto the new mesh without redoing it by hand: it copies mesh attributes from a source object onto a target based on proximity or topology, not by requiring the two meshes to match vertex-for-vertex.

How it works

This wraps Blender's Data Transfer operator directly, and it's the most parameter-heavy node in this pack's Blender set for a reason - it's exposing Blender's full data-transfer configuration rather than a simplified subset, right down to the "…+1 more" truncation you'll see on the data_type list in the raw schema (Blender supports more transferable data types than fit in a short sample). If you've used this operator in Blender's own Object menu, everything here will be familiar; if you haven't, the shape of it is: pick what to transfer, then pick how Blender should map source geometry onto target geometry, since the two meshes are rarely identical.

The inputs and outputs that matter

The two you actually need to set:

  • BPY_OBJ - the target object receiving the data (source is implied by whatever object is active/selected in the Blender scene at that point in the chain).
  • data_type - what you're transferring: UV, VGROUP_WEIGHTS (vertex group weights, i.e. rigging weights), COLOR_VERTEX, CUSTOM_NORMAL, SHARP_EDGE, SEAM, CREASE, and several more. This is the setting that actually determines what the node does - pick the one matching what you lost when you rebuilt the mesh.

A handful of mapping options (vert_mapping, edge_mapping, loop_mapping, poly_mapping) control how source geometry gets matched to target geometry when the two don't line up vertex-for-vertex - TOPOLOGY if the meshes genuinely match, NEAREST-family options if they don't. mix_mode and mix_factor control whether new data replaces or blends with what's already on the target. Defaults are reasonable for a straightforward "just carry this over" transfer; you mostly only need to touch data_type and, if the geometry differs a lot, the mapping mode.

Output is a single BPY_OBJ, the target object with the transferred data now applied.

How to install it

ComfyUI Manager, search "Avatar Graph", install, restart - or manually:

cd ComfyUI/custom_nodes
git clone https://github.com/avatechai/avatar-graph-comfyui

then pip install -r requirements.txt and restart. Requires Blender's bpy module, pinned to Python 3.10.x - build a dedicated conda environment on macOS/Linux rather than reusing a newer ComfyUI install, or use Avatech's prebuilt Python-3.10 ComfyUI zip on Windows and install the pack through Manager on top.

Common issues & troubleshooting

If the node won't load, that's the pack's Python version pin - check ComfyUI's startup console for an import error and confirm you're on a clean Python 3.10.x environment with requirements.txt fully installed.

If the transfer runs but nothing visibly changes, the most likely cause is a data_type mismatch - pick UV when you actually needed VGROUP_WEIGHTS, and the operation succeeds without error but doesn't fix the problem you were trying to fix. The second most likely cause is the mapping mode: with very different source/target topology, TOPOLOGY mapping will silently fail to transfer anything meaningful since it assumes matching vertex structure - switch to one of the NEAREST variants when the meshes genuinely differ in vertex count or layout.

Categoryblender

Inputs (19)

NameTypeDefaultDescription
BPY_OBJoptBPY_OBJ
use_reverse_transferoptBOOLEANfalse
use_freezeoptBOOLEANfalse
data_typeoptCOMBO13 options: VGROUP_WEIGHTS, BEVEL_WEIGHT_VERT, COLOR_VERTEX, SHARP_EDGE, SEAM, CREASE, +7
use_createoptBOOLEANtrue
vert_mappingoptCOMBO7 options: TOPOLOGY, NEAREST, EDGE_NEAREST, EDGEINTERP_NEAREST, POLY_NEAREST, POLYINTERP_NEAREST, +1
edge_mappingoptCOMBO5 options: TOPOLOGY, VERT_NEAREST, NEAREST, POLY_NEAREST, EDGEINTERP_VNORPROJ
loop_mappingoptCOMBO6 options: TOPOLOGY, NEAREST_NORMAL, NEAREST_POLYNOR, NEAREST_POLY, POLYINTERP_NEAREST, POLYINTERP_LNORPROJ
poly_mappingoptCOMBO4 options: TOPOLOGY, NEAREST, NORMAL, POLYINTERP_PNORPROJ
use_auto_transformoptBOOLEANfalse
use_object_transformoptBOOLEANtrue
use_max_distanceoptBOOLEANfalse
max_distanceoptFLOAT1.000–3.402823466385289e+38
ray_radiusoptFLOAT0.000–3.402823466385289e+38
islands_precisionoptFLOAT0.100–10
layers_select_srcoptCOMBO4 options: ACTIVE, ALL, BONE_SELECT, BONE_DEFORM
layers_select_dstoptCOMBO3 options: ACTIVE, NAME, INDEX
mix_modeoptCOMBO7 options: REPLACE, ABOVE_THRESHOLD, BELOW_THRESHOLD, MIX, ADD, SUB, +1
mix_factoroptFLOAT1.000–1

Outputs (1)

NameTypeDescription
BPY_OBJBPY_OBJ