The problem is that I have to load the text file and call addAttrib every frame for it to persist, costing very precious milliseconds. Am I approaching this wrong? I just need some way to take my data and present it to next node (This OpenCL node: https://www.sidefx.com/forum/topic/44718/). [sidefx.com]
Ideally I'd like to only load the txt file once, maybe if frame is 1 or with some reload button.
I'd really appreciate some help with this, thanks.
I think with attributes you may need to check if they exists before you add them.
node = hou.pwd() geo = node.geometry()
# Add code to modify contents of geo. # Use drop down menu to select examples.
curAttrib = geo.findGlobalAttrib("my_detail") if curAttrib == None: # Time to create attribute. s = 1.0 curAttrib = geo.addAttrib(hou.attribType.Global, "my_detail", s)
Using Houdini Indie 20.0 Windows 11 64GB Ryzen 16 core. nVidia 3050RTX 8BG RAM.