I am trying to get the imageplane shape node  so that its attribute 
"imageName" can be read

so far I have this 
    def connectedImgPlanes(self,dagNode):
        print "dagNode ",dagNode ,type(dagNode)
        lc=""
        try:
            lc=cmds.listRelatives(cmds.listRelatives(dagNode)[0])[0]
        except TypeError:
               return ""
        print lc
        atribVal=cmds.getAttr(lc+".imageName")
        return atribVal

the above code works fine if their is only one camera connected to 
imageplane , but I have more than one camera's imageplane set i get error 
saying " More than one object matches name: imagePlane1"

I guess this is not the right way to traverse and get the ip shape node 
please help me out....

-- 
view archives: http://groups.google.com/group/python_inside_maya
change your subscription settings: 
http://groups.google.com/group/python_inside_maya/subscribe

Reply via email to