import maya.cmds as cmds
shadingNetwork = cmds.hyperShade('blinn1', ldn=True)
print(shadingNetwork)
But this keeps returning 'None' even when there are textures attached to the material. I actually found a work around using listHistory(), but I was still curious why the ldn flag was not working as I had expected.
Thanks!
Aren
Do you get the same result if you pass it a string filter? ( ,ldn="*" )
I might be wrong but I don't think the ldn flag accepts a Boolean...
Do you get the same result if you pass it a string filter? ( ,ldn="*" )
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/98a178cf-88c9-43a8-a3c7-48b8622d6e5b%40googlegroups.com.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
Ya, they take the name of a node, and also the hyperShade command doesn't use an argument. Just keyword params:If you want the textures connected to the shader, then maybe you actually want the upstream nodes?cmds.hyperShade(lun="blinn1")
On Thu, Feb 20, 2014 at 8:26 AM, Ævar Guðmundsson <aevar.gu...@gmail.com> wrote:
I might be wrong but I don't think the ldn flag accepts a Boolean...
Do you get the same result if you pass it a string filter? ( ,ldn="*" )
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/fe0bf811-2330-4021-bba5-1b090fb83628%40googlegroups.com.To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_m...@googlegroups.com.
You probably want to look at listConnections with the plugs flag.
On Thu, Feb 20, 2014 at 3:17 PM, Aren Voorhees <are...@gmail.com> wrote:
Actually, one other question if I can - I'm wondering if anyone knows a way to tell what material slot a particular node is plugged into? For example, if I have a file plugged into the 'Color' slot of a material, can I get that info listed out somehow?
On Wednesday, February 19, 2014 8:02:08 PM UTC-6, Aren Voorhees wrote:
You're right - that'll teach me to pay more attention to the flags. And you're correct Justin, I should have used the lun flag to get the rest of the network.
Thank you both!
On Wednesday, February 19, 2014 2:27:21 PM UTC-6, Justin Israel wrote:
Ya, they take the name of a node, and also the hyperShade command doesn't use an argument. Just keyword params:If you want the textures connected to the shader, then maybe you actually want the upstream nodes?cmds.hyperShade(lun="blinn1")
On Thu, Feb 20, 2014 at 8:26 AM, Ævar Guðmundsson <aevar.gu...@gmail.com> wrote:
I might be wrong but I don't think the ldn flag accepts a Boolean...
Do you get the same result if you pass it a string filter? ( ,ldn="*" )
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsubscribe@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/python_inside_maya/98a178cf-88c9-43a8-a3c7-48b8622d6e5b%40googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.
--
You received this message because you are subscribed to the Google Groups "Python Programming for Autodesk Maya" group.
To unsubscribe from this group and stop receiving emails from it, send an email to python_inside_maya+unsub...@googlegroups.com.