Hi everyone.
I have an Fbx file that comes from Revit with a few layers, and Houdini translates them into groups. Unfortunately it also creates a group per each object that goes like “@Layername<Objectname>”
Now i need to get rid of all the “<Objectname>” and instead leave only “@Layername” possibly deleting the “@” at the beginning.
I need to keep the groups as simple as “Walls” “Doors” etc.
What would be the best way to go?
Example in the image
Simplifying FBX geometry group names
1617 3 0- Flatland
- Member
- 43 posts
- Joined: Dec. 2017
- Offline
- Flatland
- Member
- 43 posts
- Joined: Dec. 2017
- Offline
So apparently i was wrong and those were not groups but piece names.
I may need then to rename all those pieces, keeping only the first part until “<” and getting rid of the remaining characters.
Would this have to be done using a loop for each geometry with some vex? or is there a node that does that in a simpler way?
I may need then to rename all those pieces, keeping only the first part until “<” and getting rid of the remaining characters.
Would this have to be done using a loop for each geometry with some vex? or is there a node that does that in a simpler way?
Edited by Flatland - May 17, 2019 19:50:47
- jsmack
- Member
- 7733 posts
- Joined: Sept. 2011
- Offline
There are a few string processing operations available in VEX such as splitting and substitution and regex. Looping is implied by the run-over type, in this case primitives.
Something like my example below may work for you.
Something like my example below may work for you.
string splits[] = split(@name, "<"); if (len(splits)>1) @name = strip(splits[0], " ");
- Flatland
- Member
- 43 posts
- Joined: Dec. 2017
- Offline
-
- Quick Links