python - How to apply custom maya manipulator with user defined context -
i'm learning maya scripting recent days , got confused how apply custom manipulator user defined context. select obj , click show manipulator tool
doesn't work. question maybe stupid cannot find out how it.
there example in devkit filmmovemanip.py
, wanna know how use it. know how load it, way how manipulator shown , use it.
add script filmmovemanip.py plugin_path , follow usage guide in file header:
# filmmovemanip.py # scripted plug-in displays manipulator # modifies film translate horizontal , vertical # values. # # use plug-in: # 1. execute following python: # import maya # maya.cmds.loadplugin("filmmovemanip.py") # maya.cmds.spfilmmovemanipctxcmd( 'spfilmmovemanipcontext1' ) # maya.cmds.setparent( 'shelf1' ) # maya.cmds.toolbutton( 'spfilmmovemanip1', cl='toolcluster', t='spfilmmovemanipcontext1', i1="filmmovemanip.xpm" ) # 2. open outliner , select camera shape such perspshape # 3. manipulator horizontal , vertical axis displayed. # 4. move axis modify film translate
Comments
Post a Comment