Hi all,
In the change log of 6.0.3.0 it mentions a new instancer procedural has been added - which works for lights. This is something that would be helpful on my current project, can anyone explain the workflow for this as I'm unable to work it out?
Many Thanks.
New instancer procedural: A new instancer procedural node has been added to create instances of shapes and lights. (#7901)The nodes to instance are defined by the nodes and optionally node_idxs parameters. Per instance transformation, visibility and shaders can be specified via the instance_matrix, instance_visibility and instance_shader parameters. Any other per instance parameter (builtin or user parameters) can be specified via array type user parameters prefixed as instance_, for example:
You can write a simple python script to create number of Arnold lights and get position data from points.
This is a very simple 10 min code, I'm new to python. But this works.
Add a new tool to shelf and copy this script to the script tab.
And make sure you select object node(with points) you want to copy lights before executing this script.
a = hou.selectedNodes() b = a[0].displayNode() pts = b.geometry().points() for pt in pts: x=pt.position()[0] y=pt.position()[1] z=pt.position()[2] light = hou.node("obj/").createNode("arnold_light") light.parm("tx").set(x) light.parm("ty").set(y) light.parm("tz").set(z)
Hey @Madivadanatamilparidy Ramamoorthy. Thanks for replying, I'll save a copy of this. However this is different to what I'm after - I'm looking to instance lights instead of copying to save on some memory overhead.
Found a solution for this involving Solaris. As you can instance lights in Arnold/Solaris, you can create the instances there then write them out as a .USD file. And then you can load in the .USD into an Arnold Procedural node at SOP level. Bit of an annoying workaround, but it works atleast.
Thanks.
Hi Jay!
SOP or OBJ?
If I correct understand, first you create light instancing in LOP, after that you write it to usda and load to Arnold procedural node in obj, correct?