5
$\begingroup$

If I make an armature like this:

enter image description here

Is there a way to automatically generate a mesh to go on the armature? to make something like this:

enter image description here

$\endgroup$
  • $\begingroup$ Use the "Skinify Rig" add-on. $\endgroup$ – Shankar Sivarajan Sep 6 at 14:08
4
$\begingroup$

Well that armature had some funny bone directions on that legs (the bones must look pointy from the abdomen like the left ones)

The tool you are searching is a Modifier called "Skin". Like modifier, can't be used over an armature. Create a cube and modify their vertex or generate new and see how it works. You can also create one armature from your vertex with the option on the modifier (activated in object mode)

More info on: http://wiki.blender.org/index.php/Doc:2.6/Manual/Modifiers/Generate/Skin

| improve this answer | |
$\endgroup$
  • 2
    $\begingroup$ As far as I know, the skin modifier requires a mesh input (it does not generate a mesh from an armature). $\endgroup$ – gandalf3 Jan 27 '14 at 21:21
  • $\begingroup$ @gandalf3 Totally agree. For that I written "Like modifier, can't be used over an armature." I preferred give one valid alternative. $\endgroup$ – gabrign Jan 27 '14 at 23:55
  • $\begingroup$ For anyone coming to this, and wants a video tutorial, then watch this tutorial: blendernation.com/2019/07/07/… It really explains in good detail how to create a good model from a simple skin modifier. $\endgroup$ – JustCarty Apr 27 at 13:11
1
$\begingroup$

I just looked for this too... no Joy.

Wrote my own.

import bpy
import math
import os

Meshname = "armature_mesh";

def convertVector(v):
    return [v.x,v.y,v.z]

def main():
    #make sure what we're going to work on is an actual armature.     
    if bpy.context.scene.objects.active.type != 'ARMATURE':
        print("Active object must be an armature!!");
        return 1;

    theArmature=bpy.context.scene.objects.active;

    #delete any previous attempts
    if bpy.data.objects.get(Meshname) is not None:
        bpy.ops.object.select_all(action='DESELECT')
        bpy.data.objects[Meshname]
        bpy.data.objects[Meshname].select = True
        bpy.ops.object.delete(use_global=False)

    #time to copy the armature to mesh
    #define our data containers for the new obj
    Verts=[]
    Edges=[]
    Faces=[]

    #select the armature and enter edit mode, and get all the bones. 
    bpy.context.scene.objects.active = theArmature
    bpy.ops.object.editmode_toggle()
    bpy.ops.armature.select_all(action='SELECT')
    bones = bpy.context.selected_bones

    #loop through the bones, putting all the coords in the data containers. 
    for bone in bones :
        Verts.append(convertVector(bone.head))
        Verts.append(convertVector(bone.tail))
        VertID = len(Verts)
        Edges.append([VertID-2,VertID-1])


    bpy.ops.object.editmode_toggle()


    #make the object and add all the data.     
    mesh=bpy.data.meshes.new(Meshname)
    mesh.from_pydata(Verts,Edges,Faces)
    newMesh=bpy.data.objects.new(Meshname,mesh)
    bpy.context.scene.objects.link(newMesh)


    #connect the connected bones by removing doubles
    bpy.context.scene.objects.active = newMesh
    bpy.ops.object.editmode_toggle()
    bpy.ops.mesh.select_all(action='SELECT')
    bpy.ops.mesh.remove_doubles()
    bpy.ops.object.editmode_toggle()

    bpy.ops.object.modifier_add(type='SKIN')


main();
| improve this answer | |
$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.