Skip to content

Instantly share code, notes, and snippets.

@kickbase
Created June 16, 2020 13:30
Show Gist options
  • Save kickbase/9d5769576b1b68aee2872cc47683aa0b to your computer and use it in GitHub Desktop.
Save kickbase/9d5769576b1b68aee2872cc47683aa0b to your computer and use it in GitHub Desktop.
[Houdini] [Python] Disconnect selected nodes.
for node in hou.selectedNodes():
for inConnection in node.inputConnections():
inIndex = inConnection.inputIndex()
inNode = inConnection.outputNode()
inNode.setInput(inIndex, None, 0)
for outConnection in node.outputConnections():
outIndex = outConnection.inputIndex()
outNode = outConnection.outputNode()
outNode.setInput(outIndex, None, 0)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment