TomRaynor Posted April 8, 2013 Share Posted April 8, 2013 I would love to know if I am using a python expression in a node's parameter.... is there a way using python to grab the name of the parameter currently being populated by the expression that you are writing? (similar to how you can use kwargs['parm'] in an otl. See attached scene where I have added a few more notes to try and explain this. Thanks, Tom test.hip Quote Link to comment Share on other sites More sharing options...
graham Posted April 8, 2013 Share Posted April 8, 2013 You can use hou.evaluatingParm() to get the current hou.Parm object. http://www.sidefx.com/docs/houdini12.5/hom/hou/evaluatingParm 1 Quote Link to comment Share on other sites More sharing options...
TomRaynor Posted April 8, 2013 Author Share Posted April 8, 2013 Thanks Graham, you've saved the day once again! That works a treat. It has brought up another little python issue which I don't quite understand. I am trying to reference a primitive attribute on my geometry via a local variable using python. It works in the hscript case but when I replicate it in python it doesn't seem to work. I was wondering if you could take a look at the "hip" and see if I am doing something silly? I realize that I haven't included the texture files so it will be hard to check if it is working, but they are quite big so I'd rather not upload them. Cheers! udimNotWorking_v01.hip Quote Link to comment Share on other sites More sharing options...
graham Posted April 8, 2013 Share Posted April 8, 2013 After correcting the fact the lvar version is returning the value as a float rather than an int, the resulting attribute values look the same to me. Quote Link to comment Share on other sites More sharing options...
TomRaynor Posted April 8, 2013 Author Share Posted April 8, 2013 Ugh, you're completely right... Thanks a lot for taking a look. 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.