rig.py 文件源码

python
阅读 27 收藏 0 点赞 0 评论 0

项目:mayakit 作者: danbradham 项目源码 文件源码
def create_joint_chain(positions, **kwargs):
    '''Create a joint chain from a list of om.MVectors'''

    aim_vects = [b - a for a, b in zip(positions, positions[1:])]
    aim_vects.append(aim_vects[-1])

    joints = [create_joint(pos, aim, **kwargs) for pos, aim, in zip(positions, aim_vects)]
    for parent, child in zip(joints, joints[1:]):
        cmds.parent(child, parent)
    cmds.setAttr(joints[-1] + '.jointOrient', 0, 0, 0) # Zero out the last joint in the chain
    return joints
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号