v11.0 (2013)
Returns the ICENodePort object that matches a specific port name. This method is similar to ICENode.GetPortFromName but specific to the python language.
Object ICENode.GetPortFromName2( String portname ); |
oReturn = ICENode.GetPortFromName2( PortName ); |
Parameter | Type | Description |
---|---|---|
PortName | String | Port name to match. |
# Demonstrate how to get a port by name in Python from siutils import * si = si() si.NewScene("",False) si.CreatePrim("Sphere", "MeshSurface", "", "") si.ApplyOp("ICETree", "sphere", "siNode", "siPersistentOperation", "", 0) si.AddICENode("ICENodes\\ColorNode.Preset", "sphere.polymsh.ICETree") node = si.GetValue('sphere.polymsh.ICETree.ColorNode') port = node.GetPortFromName2('Value') log( port.GetValueAtFrame(0) ) |