This subjects has come up a lot of times, but how can you handle it when you have a lot of attributes and you want to convert all of them to groups whatever their name is.
I need to do this because i want to cycle through my primitives based on attributes, like a quick filter. So groups i think is the best way using a blast, each time selecting a different group and seeing which objects have a particular attribute.
Convert multiple attributes to groups
4921 8 2- papsphilip
- Member
- 385 posts
- Joined: 7月 2018
- Offline
- rpopovici
- Member
- 31 posts
- Joined: 3月 2017
- Offline
- CYTE
- Member
- 679 posts
- Joined: 2月 2017
- Offline
- papsphilip
- Member
- 385 posts
- Joined: 7月 2018
- Offline
rpopovici
I don't understand what you are trying to do here, but you can take a look at these SOPs: Connectivity SOP, Partition SOP, Name SOP, Group Expression SOP, and Group Promote SOP. They all deal with groups form attributes or the opposite..
I know, but i havent found a way to convert every attribute into a group, not just one or two that i know their name but all of them at once.
There is probably a rule in partition sop that can do this but i have no idea
- Andr
- Member
- 900 posts
- Joined: 2月 2016
- Offline
Hello, you might want to look at doing it in a python node:
https://www.sidefx.com/docs/houdini/hom/hou/Geometry.html [www.sidefx.com]
pointAttribs() and primAttribs() functions can help you to return tuples of the attributes in the geometry ('P' included), then you can loop over them to extract their name()
cheers
https://www.sidefx.com/docs/houdini/hom/hou/Geometry.html [www.sidefx.com]
pointAttribs() and primAttribs() functions can help you to return tuples of the attributes in the geometry ('P' included), then you can loop over them to extract their name()
cheers
Edited by Andr - 2019年6月3日 15:06:30
- BabaJ
- Member
- 2040 posts
- Joined: 9月 2015
- Offline
- BabaJ
- Member
- 2040 posts
- Joined: 9月 2015
- Offline
- papsphilip
- Member
- 385 posts
- Joined: 7月 2018
- Offline
BabaJ
Or…if you want to just scroll through the prims via their names(without having to type the names themselves).
sorry for the delay, i found some time to look at it now. This could be usefull if the attributes were a few and i knew their names.This is definitely a step forward but, i have an osm file with a lot of attributes and ideally i want this ordered menu you made to be created automatically for me so that i can select a random attribute and see which primitives are included. Maybe i can tweak the primitive wrangle.
Edited by papsphilip - 2019年6月14日 01:41:14
- BabaJ
- Member
- 2040 posts
- Joined: 9月 2015
- Offline
I think with python a script could be set up to get the menu item labels correspond to the attribute name.
Not sure if that is too much work for what you need.
But my hip file did give a different option with the slider parameter ( just tick off the “Scroll Through” box to activate the slider).
Then with a geometry spreadsheet open look at the @Show attribute…that lists the primitive by name isolated by your slider.
Doesn't matter if you have alot of them, you can quickly find one by name.
Not sure if that is too much work for what you need.
But my hip file did give a different option with the slider parameter ( just tick off the “Scroll Through” box to activate the slider).
Then with a geometry spreadsheet open look at the @Show attribute…that lists the primitive by name isolated by your slider.
Doesn't matter if you have alot of them, you can quickly find one by name.
-
- Quick Links