magneto Posted December 29, 2011 Share Posted December 29, 2011 I have a curve that I create using a custom Python SOP, but I also want to change point colors so they are not white. I looked at the docs but there isn't a color property to set. So I thought I probably need to set the CD attribute but I couldn't get it to work because never did this before in code. I tried setting the attrib value but it seems like points only has P, Pw (?) I think, when I listed them. Do I have to create an attrib called CD first? Anyone did this before? Thanks. Quote Link to comment Share on other sites More sharing options...
graham Posted December 29, 2011 Share Posted December 29, 2011 (edited) Yes, you need to create the Cd attribute first if it doesn't already exist. attr = geo.addAttrib(hou.attribType.Point, "Cd", (0.0, 0.0, 0.0)) for point in geo.points(): point.setAttribValue(attr, some_color_tuple) Edited December 29, 2011 by graham 2 Quote Link to comment Share on other sites More sharing options...
magneto Posted December 29, 2011 Author Share Posted December 29, 2011 It worked great. Thanks man Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.