pwd()
→ hou.OpNode
This function is a shortcut for writing hou.node(".")
.
Note that Python and hscript both share the same global current node. So, if you change that node in hscript, the return value of pwd() will reflect that change, and vice versa.
Note that if this function is called from an expression inside a node’s
parameter, Houdini will return the node containing the expression, not
Houdini’s current node. This behavior permits relative parameter and
node references from both Hscript and Python parameter expressions, since
functions like hou.ch(), ch, hou.evalParm(), hou.parm(),
and hou.node() are relative to the result of hou.pwd()
.
This function will raise hou.NotAvailable if you call it from MPlay.
See also |