pyNode

Parent: ygNode Example Source code Header file

Description

A pyNode loads a Python script and creates an object of a class defined in that script. The script can perform any standard Python operations; additional modules (ygdrasil and ygNode) are defined to provide interfaces to Ygdrasil features.

The Python object's app() function will be called once per frame, by pyNode::app().

Messages

scriptstring [, string]load a Python script and create an object
reloadreload the script previously loaded by script
autoResetbooltell the node to automatically reset any time the script file is modified
callstringcall a function on the Python object

See pyInterface for details on what these messages do.

Events

pyNode itself does not generate any events. The Python scripts can generate their own events, however.

Keys

None.

Python Notes

All of pyNode's behavior is actually implemented in the class pyInterface; each pyNode node creates a pyInterface object to handle all the Python code. This is done so that other Python-node classes can also use the pyInterface class, since they cannot be derived from pyNode (e.g., pyTransform is derived from ygTransform).


Last updated 13 September 2002.
home page