ivan Posted January 3, 2012 Share Posted January 3, 2012 is there any way to determine if a three dimansional tuple is a point or a color? i.e: >>>mytuple = hou.node("shop/mythingy").parmTuples()[10] >>>mytuple.name() 'foo' >>>len(mytuple) 3 great. now, is the UI for mytuple a "point" or is it a "color"? is it possible to determine this? Quote Link to comment Share on other sites More sharing options...
ivan Posted January 3, 2012 Author Share Posted January 3, 2012 also, being able to tell if an int parm is a toggle in the UI would be helpful, too..... Quote Link to comment Share on other sites More sharing options...
rdg Posted January 3, 2012 Share Posted January 3, 2012 (edited) hou.ParmTemplate[1] will lead you the way. The look of tge parmTemplate tells you if it's a color or a float[3] widget. The type of the parmTemplate tells you if it's a toggle or an integer. >>> hou.parm('/obj/null1/parm1').parmTemplate().type() parmLook.ColorSquare >>> hou.parm('/obj/null1/parm2').parmTemplate().type() parmLook.Regular >>> hou.parm('/obj/null1/parm3').parmTemplate().type() parmTemplateType.Int >>> hou.parm('/obj/null1/parm4').parmTemplate().type() parmTemplateType.Int >>> hou.parm('/obj/null1/parm4').parmTemplate().type() == hou.parmTemplateType.Int True [1] http://www.sidefx.com/docs/houdini11.1/hom/hou/ParmTemplate Edited January 3, 2012 by rdg Quote Link to comment Share on other sites More sharing options...
rdg Posted January 3, 2012 Share Posted January 3, 2012 (edited) ... Edited January 3, 2012 by rdg Quote Link to comment Share on other sites More sharing options...
ivan Posted January 3, 2012 Author Share Posted January 3, 2012 right, so, >>> mytuple.parmTemplate().look() parmLook.ColorSquare and for my toggle, >>> myothertuple.parmTemplate().type() parmTemplateType.Toggle yay! Quote Link to comment Share on other sites More sharing options...
edward Posted January 3, 2012 Share Posted January 3, 2012 See also hou.ParmTemplate.namingScheme() Quote Link to comment Share on other sites More sharing options...
ivan Posted January 3, 2012 Author Share Posted January 3, 2012 thank you, yet again, Georg! Quote Link to comment Share on other sites More sharing options...
ivan Posted January 3, 2012 Author Share Posted January 3, 2012 Edward, too! 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.