top of page
Search
Writer's pictureKevfx Studios

Houdini Python - Node Search

Updated: Jun 27, 2022

In this post, I will give some examples of how to search nodes in your current Houdini scene.

(This post will be updated.)


Search by type


import nodesearch
matcher = nodesearch.NodeType('kevfx_python_tools', hou.objNodeTypeCategory())
nodes = matcher.nodes(hou.node('/obj'))

This is to search for obj nodes which type is 'kevfx_python_tools' under “/obj” node.

Some notes here:

  • NoteType is initialised with two arguments: node type name and node category.

  • It will try to search for an object level node which has type name 'kevfx_python_tools'.

  • It is searching the nodes under /obj node.

  • If you need to search in the subnetworks, use this line of code instead:

nodes = matcher.nodes(hou.node('/obj'), recursive=True)

38 views0 comments

Comments


bottom of page