Link to video:
Redshift Generate Sequential Numbering for OBJ ID
3228 2 2- BrettAHanson
- Member
- 6 posts
- Joined: Jan. 2017
- Offline
I was watching a video from Greyscalegorilla in creating Redshift custom AOVs for control in the composite. About half way through the video, he made a sequential numbering for the object IDs based on the selected objects with an expression. I was wondering how to do this same task in Houdini to create a sequential numbering to change the object IDs for the objects in Houdini. This would be nice to know since I would not have to manually set each and every object for the object ID to have a matte in Redshift.
Link to video:
Link to video:
- Anthony Morrelle
- Member
- 39 posts
- Joined: Dec. 2013
- Offline
A quick and dirty way would be to use Python to add sequential numbers to your nodes that you select.
Select what nodes you want to add the object id's to and open the python shell:
There is probably a better, more obvious way but this works ok.
Select what nodes you want to add the object id's to and open the python shell:
nodes = hou.selectedNodes() for idx,item in enumerate(nodes): updateitem = item.parm("RS_objprop_ID").set(idx)
There is probably a better, more obvious way but this works ok.
Edited by Anthony Morrelle - Jan. 2, 2020 17:20:19
Anthony Morrelle
Hired Gun
Hired Gun
- BrettAHanson
- Member
- 6 posts
- Joined: Jan. 2017
- Offline
-
- Quick Links