As an aside, image planes aren't DAG nodes and thus don't have shapes/transforms associated with them. When you select an image plane in the viewport you're actually selecting that image plane's camera.
On Friday, October 19, 2012 10:38:09 AM UTC-7, San Luthra wrote: > > 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
