Sunday, September 25, 2011

Shader Work

References:
http://www.mail-archive.com/python_inside_maya@googlegroups.com/msg04471.html
http://tech-artists.org/forum/showthread.php?t=1279
http://download.autodesk.com/global/docs/maya2012/ja_jp/PyMel/generated/pymel.core.rendering.html#module-pymel.core.rendering
http://autodesk.com/us/maya/2011help/CommandsPython/hyperShade.html 
http://autodesk.com/us/maya/2011help/CommandsPython/shadingNode.html
http://forums.cgsociety.org/archive/index.php/t-767023.html


Code:
So this is kinda working..
import maya.cmds as cmds
cmds.shadingNode('misss_fast_shader', asUtility=True, name='skin' )
but it's only creating it in the Work Area, not creating an actual shader, helpful for later though 

[27Sept]
Got it! Set asShader=True
cmds.shadingNode('misss_fast_shader', asShader=True, asUtility=True, name='skin' )
other options -asTexture -asLight -asPostProcess -asUtility

then to add a new texture to map
cmds.shadingNode('lambert', asTexture=True, asUtility=True, name='skin' )
so maybe I don't need the asUtility...?

No comments:

Post a Comment