If I have a stirng parameter which I may assign a space limeted group names list (as it happens automatically with ui) - do I need to tokenize it to access entries with separated findGroup calls, or it is sufficient to pass that string, to get all entries already united from different groups?
sample code
GB_PointGroup* ptgrp1 = gdp->findPointGroup(“group1”);
GB_PointGroup* ptgrp2 = gdp->findPointGroup(“group2”);
// …PARSE AND UNITE GROUPS
or
GB_PointGroup* ptgrp = gdp->findPointGroup(“group1 group2”);
// …GROUP IS ALREADY COLLECTED AND UNITED
which code is working?
Thank you!
HDK: groups parsing
3282 6 1- JOEMI
- Member
- 128 posts
- Joined: July 2005
- Offline
- edward
- Member
- 7752 posts
- Joined: July 2005
- Offline
- wei750830
- Member
- 46 posts
- Joined: Jan. 2012
- Offline
- Anonymous
- Member
- 678 posts
- Joined: July 2005
- Offline
+1 to this topic. Some time ago I wrote to SESI support with almost the same question. I wanted to know what the hell is going on behind the curtain in each of the parseGroups() methods. Since I don't own Houdini or work in any company that use it (or in 3D industry at all), I couldn't get the answers. And there are no info about them in examples too.
I use it in one of my Sops but in another one where I needed to filter multiple groups it gived me strange results, for example, it didn't notice that one of the specified groups was not existing at all and and since other two where correct it parsed without noticing it. More examples about parsing parameters with built in methods would be really nice.
I use it in one of my Sops but in another one where I needed to filter multiple groups it gived me strange results, for example, it didn't notice that one of the specified groups was not existing at all and and since other two where correct it parsed without noticing it. More examples about parsing parameters with built in methods would be really nice.
- edward
- Member
- 7752 posts
- Joined: July 2005
- Offline
Sorry, I'm not sure what the confusion is? parseGroups(), parsePrimitiveGroups(), parsePointGroups(), etc. take a Houdini group pattern string value (ie. the values used for those Group parameters in SOPs) and generate a GA_ElementGroup subclass for use.
The parsing is not very strict on purpose, and their syntax is documented:
http://www.sidefx.com/docs/houdini12.5/model/groups#manual [sidefx.com]
The parsing is not very strict on purpose, and their syntax is documented:
http://www.sidefx.com/docs/houdini12.5/model/groups#manual [sidefx.com]
- wei750830
- Member
- 46 posts
- Joined: Jan. 2012
- Offline
- edward
- Member
- 7752 posts
- Joined: July 2005
- Offline
-
- Quick Links