Skip to content

Instantly share code, notes, and snippets.

@kickbase
Created February 27, 2022 06:05
Show Gist options
  • Save kickbase/d084f679ee6cea17edfe234e5a805775 to your computer and use it in GitHub Desktop.
Save kickbase/d084f679ee6cea17edfe234e5a805775 to your computer and use it in GitHub Desktop.
[Houdini] [Python] Clear params button in HDA
node = hou.pwd()
geo = node.geometry()
for p in node.parms():
try:
if p.name() != "python":
p.revertToDefaults()
except:
pass
@kickbase
Copy link
Author

Button callback Script: exec(hou.pwd().parm("python").eval());

python parameter (multi-line string) is invisibled.

@kickbase
Copy link
Author

to refresh inside folder0:

node = hou.pwd()
geo = node.geometry()

l = node.parm("folder0").eval()

for i in range(l):
    p = node.parm("slider{}".format(i+1))
    p.revertToDefaults()
    

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment