Last active
April 14, 2021 18:31
-
-
Save tcrowson/8273554 to your computer and use it in GitHub Desktop.
For Softimage.
Searches for 'Store_Color_In_Channel' nodes and adds their channels to the scene channel list.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# loop through shader nodes in the scene, identify 'store_color_in_channel' nodes, | |
# and add them to the scene globals. Avoid duplicate channnels. | |
for x in Application.FindObjects("", "{6495C5C1-FD18-474E-9703-AEA66631F7A7}" ): | |
if str(x.ProgID) == "Softimage.sib_color_storeinchannel.1.0": | |
chanName = Application.GetValue(x.Channel) | |
addChan = Application.CreateRenderChannel("%s"%(chanName), "siRenderChannelColorType", "") | |
newChan = (addChan[-1]) | |
if newChan.isdigit(): | |
Application.RemoveRenderChannel(addChan) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment