Skip to content

Instantly share code, notes, and snippets.

@gfxhacks
Created June 19, 2020 16:51
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
Star You must be signed in to star a gist
Embed
What would you like to do?
Basic Python Parameter creation workflow in Houdini: https://gfxhacks.com/create-parameters-in-houdini-with-python
# get node (find the path in your node's info panel)
n = hou.node("/path/to/node")
# get existing list of parameters for the specified node
g = n.parmTemplateGroup()
# define new float parameter ("id", "Label", components/input fields, default values)
p = hou.FloatParmTemplate("myParm", "My Parameter", 3, default_value=[1, 1, 1])
# append the new parameter to the list
g.append(p)
# apply changes
n.setParmTemplateGroup(g)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment