Object Convert
ComfyUI Node Guide
- BPY_OBJ
- BPY_OBJ
Object Convert is Blender's "Convert To" command - the one buried in the object right-click menu that switches what kind of data an object actually holds - exposed as a node in Avatar Graph, Avatech's pack for rigging character illustrations into real-time avatars inside ComfyUI. It's not a node you'll use constantly, but when you need it, nothing else in the pack does this job.
It wraps bpy.ops.object.convert directly, mirroring the real operator's full parameter set. The core idea: Blender objects come in different data types - mesh, curve, grease pencil, curves (hair-style curves) - and this operator converts one type into another. A text object you built with Object Text Add, for instance, isn't a mesh - it's font data - and if you need actual polygon geometry out of it (to deform it, unwrap it, join it into another mesh), you'd run it through this node with target: MESH first.
The inputs worth understanding:
- target - what type to convert into:
CURVE,MESH,GPENCIL, orCURVES. This is the whole point of the node; everything else configures how the conversion happens depending on which direction you're going. - keep_original - if true, the source object stays around unchanged and a new converted copy is created alongside it; if false (the default), the original is replaced.
- merge_customdata - whether custom data (like UVs or vertex colors) gets merged sensibly during conversion, default on, generally fine left alone.
- angle, thickness, offset, seams, faces - these mostly apply to curve-related conversions (curve-to-mesh thickness/fill behavior, or mesh-to-curve angle thresholds for deciding what counts as an edge to trace). If you're doing a straightforward mesh conversion, the defaults are sensible and you likely won't touch these.
Output is the same BPY_OBJ, now holding the converted data type.
Where this actually matters in an avatar-rigging workflow: most of Avatar Graph's pipeline stays in mesh-land - segmented image layers become meshes, get unwrapped, get textured, get rigged. Convert is your escape hatch when a node elsewhere in the graph hands you a non-mesh object type (text, a curve) and you need it as geometry to continue.
Installing it: no standalone install - you get this with the entire Avatar Graph pack. Simplest route is ComfyUI Manager, search "Avatar Graph" or avatar-graph-comfyui. Manual: cd ComfyUI/custom_nodes && git clone https://github.com/avatechai/avatar-graph-comfyui, then cd in and pip install -r requirements.txt, restart ComfyUI.
The install snag that actually gets people: Avatar Graph needs Python 3.10.x specifically, because its bpy dependency only ships wheels for that version. A newer Python - which is the default on most current ComfyUI setups - means the install fails outright. The README's fix is a dedicated environment: conda create --name comfyui python=3.10, activate, install ComfyUI's requirements first, then this pack's. For the live avatar preview in Avatech's own web editor, also launch with --enable-cors-header (Mac: add --force-fp16); without it, conversions and everything else still work, you just export .glb/.gltf and view results elsewhere instead of getting the live in-browser preview.
One thing to watch: if you convert to MESH from something like a text object and the result looks emptier than expected, double-check enter_editmode wasn't left on somewhere upstream on the source object - an object mid-edit can convert unexpectedly.
Inputs (9)
| Name | Type | Default | Description |
|---|---|---|---|
| BPY_OBJopt | BPY_OBJ | — | |
| targetopt | COMBO | 4 options: CURVE, MESH, GPENCIL, CURVES | |
| keep_originalopt | BOOLEAN | false | — |
| merge_customdataopt | BOOLEAN | true | — |
| angleopt | FLOAT | 1.220–3.141592741012573 | — |
| thicknessopt | INT | 51–100 | — |
| seamsopt | BOOLEAN | false | — |
| facesopt | BOOLEAN | true | — |
| offsetopt | FLOAT | 0.010–999999995904 | — |
Outputs (1)
| Name | Type | Description |
|---|---|---|
| BPY_OBJ | BPY_OBJ | — |