def applyTargets(context):
    ob = context.object
    bpy.ops.object.mode_set(mode='OBJECT')
    verts = evalVertLocations(ob)   
    utils.removeShapeKeys(ob)
    for prop in ob.keys():
        del ob[prop]
    for v in ob.data.vertices:
        v.co = verts[v.index]
    return
def applyTargets(context):
    ob = context.object
    bpy.ops.object.mode_set(mode='OBJECT')
    verts = evalVertLocations(ob)
    utils.removeShapeKeys(ob)
    for prop in ob.keys():
        del ob[prop]
    for v in ob.data.vertices:
        v.co = verts[v.index]
    return
Exemple #3
0
def createTestFace(context, warpField, mask):
    scn = context.scene
    scn.objects.active = mask
    bpy.ops.object.duplicate()
    ob = context.object
    ob.name = "Test"
    utils.removeShapeKeys(ob)
    ob.layers[2] = True
    ob.layers[0] = False
    print(ob)
    for v in mask.data.vertices:
        v1 = ob.data.vertices[v.index]
        v1.co = warpField.warpLoc(v.co)
Exemple #4
0
def createTestFace(context, warpField, mask):
    scn = context.scene
    scn.objects.active = mask
    bpy.ops.object.duplicate()
    ob = context.object
    ob.name = "Test"
    utils.removeShapeKeys(ob)
    ob.layers[2] = True
    ob.layers[0] = False
    print(ob)
    for v in mask.data.vertices:
        v1 = ob.data.vertices[v.index]
        v1.co = warpField.warpLoc(v.co)
 def execute(self, context):
     mh.proxy = None
     ob = context.object
     for mod in ob.modifiers:
         if mod.type == 'ARMATURE':
             mod.show_in_editmode = True
             mod.show_on_cage = True
         else:
             ob.modifiers.remove(mod)
     utils.removeShapeKeys(ob)
     ob.shape_key_add(name="Basis")
     ob["NTargets"] = 0
     ob["ProxyFile"] = 0
     ob["ObjFile"] =  0
     ob["MhxMesh"] = True        
     return{'FINISHED'}    
 def execute(self, context):
     mh.proxy = None
     ob = context.object
     for mod in ob.modifiers:
         if mod.type == 'ARMATURE':
             mod.show_in_editmode = True
             mod.show_on_cage = True
         else:
             ob.modifiers.remove(mod)
     utils.removeShapeKeys(ob)
     ob.shape_key_add(name="Basis")
     ob["NTargets"] = 0
     ob["ProxyFile"] = 0
     ob["ObjFile"] = 0
     ob["MhxMesh"] = True
     return {'FINISHED'}