Search - User list
Full Version: group-name from name attribute
Root » Houdini Indie and Apprentice » group-name from name attribute
soulcage_dpt
hi,

i have some points with a name attribute.
i want to create groups with the group-name from this name-attribute, but the group node doesnt accept @name as the group-name.
does somebody know how to achieve this?
(i need these group-names for better selection points on the rivet obj node...)
Enivob
Wouldn't that just be a one-liner inside a point wrangle? (assuming name is actually on points and not prims)
setpointgroup(0, s@name, @ptnum, 1, "set");
sepu
You could also use groups from name sop. If I understand correctly what you want.
soulcage_dpt
thx a lot for the hints...

@Enivob, this works perfect, thx for the snippet (had to rename the name-attribute since it contained a namespace-character ":" and it seems group-names dont like ":")

@sepu, the "groups from name" sop doesnt exist in 19.0.xx, seems only be available in 19.5.xx, but this also works perfect in 19.5.xx, the renaming of the namespace-character is then automatically...thx
djdoogle123
soulcage_dpt
thx a lot for the hints...

@Enivob, this works perfect, thx for the snippet (had to rename the name-attribute since it contained a namespace-character ":" and it seems group-names dont like ":")

@sepu, the "groups from name" sop doesnt exist in 19.0.xx, seems only be available in 19.5.xx, but this also works perfect in 19.5.xx, the renaming of the namespace-character is then automatically...thx

Hi Im not sure if you can help but seems you had a similar problem,

I have rbd sim but in that before the fracture I use an attribute create to create an attribute name in the string to use as a geoup to apply separate materials too. But except when it comes to the rbd bullet solver it doesn’t like it as it also uses a name attribute what would be a good work around here?

Regards
BabaJ
djdoogle123
But except when it comes to the rbd bullet solver it doesn’t like it as it also uses a name attribute what would be a good work around here?

Before you run your geo through the sim, you could make an attribute like 'original_name' and assign the values as if it was 'name'.
Then after the sim, you could delete all 'name' attributes with delete attribute sop, except 'original_name' attribute.

Then use the rename attribute sop to change your 'original_name' to 'name'.
djdoogle123
BabaJ
djdoogle123
But except when it comes to the rbd bullet solver it doesn’t like it as it also uses a name attribute what would be a good work around here?

Before you run your geo through the sim, you could make an attribute like 'original_name' and assign the values as if it was 'name'.
Then after the sim, you could delete all 'name' attributes with delete attribute sop, except 'original_name' attribute.

Then use the rename attribute sop to change your 'original_name' to 'name'.


I’m not really sure what you mean could you show me an example?

Regards
BabaJ
Red colored nodes.
This is a "lo-fi" version of our main content. To view the full version with more information, formatting and images, please click here.
Powered by DjangoBB