Hi all,
I'm trying to set the “rule” parameter in the Partition SOP to `@shop_materialpath` using Python but it does not seem to recognize the back ticks.
Any help?
Thanks.
# python partition node
obj = hou.node(“/obj”)
geo = obj.createNode('geo')
partition = geo.createNode('partition')
path = “`@shop_materialpath`”
partition.parm('rule').set(path)
Python back ticks in parameters
1200 2 0- GEODVS
- Member
- 14 posts
- Joined: 6月 2018
- Offline
- blackpixel
- Member
- 182 posts
- Joined: 4月 2009
- Offline
it should work. I tried your code and the quotation marks were invalid. Try this one (made them all the same for consistency):
# python partition node obj = hou.node('/obj') geo = obj.createNode('geo') partition = geo.createNode('partition') path = '`@shop_materialpath`' partition.parm('rule').set(path)
- GEODVS
- Member
- 14 posts
- Joined: 6月 2018
- Offline
-
- Quick Links