Пример #1
0

# import pymel.core as pm
import maya.standalone
maya.standalone.initialize(name='python')

import maya.cmds as cmds
import os

# import Red9_Meta as r9Meta
import Red9.core.Red9_Meta as r9Meta
import Red9.core.Red9_CoreUtils as r9Core
import Red9.core.Red9_PoseSaver as r9Pose

import Red9.startup.setup as r9Setup
r9Setup.start(Menu=False)

# force the upAxis, just in case
r9Setup.mayaUpAxis('y')


red9MetaRigConfig = os.path.join(r9Setup.red9Presets(), 'Red9_MetaRig_unitTest.cfg')

def getPoseFolder():
    return os.path.join(r9Setup.red9ModulePath(), 'tests', 'testFiles', 'MetaRig_Poses')

class Test_MetaRig():
    '''
    these are wrapped calls on MetaRig itself, note that compare goes via
    the skeletonDict in the internal metaRig compare calls
    '''
Пример #2
0
This is the main unittest for the Red9_Meta module and a good
example of what's expected and what the systems can do on simple data
================================================================

'''


#import pymel.core as pm
import maya.standalone
maya.standalone.initialize(name='python')

import Red9.core.Red9_AnimationUtils as r9Anim
import Red9.startup.setup as r9Setup
import maya.cmds as cmds
import os
r9Setup.start(Menu=False)

#force the upAxis, just in case
r9Setup.mayaUpAxis('y')

class Test_MirrorSetups(object):
    def setup(self):
        
        self.leftWrist='leftWrist'
        self.leftFoot = 'leftFoot'
        self.rightWrist = 'rightWrist'
        self.rightFoot = 'rightFoot'
        self.root = 'root'
        
        cmds.polyCube(n=self.leftWrist)[0]
        cmds.polyCube(n=self.leftFoot)[0]