Search the Community
Showing results for tags 'createnode'.
-
ISSUE: Trying to create a "HeightField File" SOP node using python. STEP #1: Make code that Houdini thinks is correct I create a hip file that has just "/obj/geo/height", a node which is of type "Heightfield File." I make code for the node using hou.node("/obj/geo/height").asCode() The node type in the generated code is "heightfield_file" as you would expect. STEP #2: Try to recreate the original file Then, using the generated code as a guide, simplifying it, I run it and get this error: hou.OperationFailed: The attempted operation failed. Invalid node type name The code I ran (with vanilla python rather then hython, because, that's epic) was: import sys, os sys.path.append( os.environ['HFS'] + "/houdini/python%d.%dlibs" % sys.version_info[:2] ) import hou hou.hipFile.clear() hou_parent = hou.node('/obj') hou_node = hou_parent.createNode("heightfield_file") ...and yes, I tried 'hython" too after removing the sys.path trick. Any hints or ideas? TIA
-
Hi, How do I find the name of a node to pass into the 'createNode()' function? I'm following a tutorial, and in it he writes: .createNode(“ifd”) to create a mantra node. But I can't figure out where I find this. I've printed the node using the ‘.asCode()’ function, but I'm not really sure what I'm looking for. Thanks a lot