have much groups(maybe group1,group2 to group100),and i want to select prims not in group to other group,
if use group combine,i have to type group1,group2,…. to group100,It's like a joke.
so wirte vex in attribwrangle
————————————————————-
string mygroup = detailintrinsic(0, “primitivegroups”);
int sss = len(mygroup);
for(int i=0;i<sss;i++)
{if (!inprimgroup(0,mygroup,@primnum))
{setprimgroup(0, “ss”, @primnum, 1);}
}
————————————————————-
it works,but houdini have other easy way to do it?
how to select not in group to other group use simple way
4060 5 0-
- darkdark132
- Member
- 11 posts
- Joined:
- Offline
-
- tamte
- Member
- 9380 posts
- Joined: July 2007
- Offline
to group everything that is not in group yet you can create Group SOP and in the Base Group type:!?*
darkdark132this can be very inefficient, if your groups don't need to overlap consider using attributes instead
have much groups(maybe group1,group2 to group100)
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- darkdark132
- Member
- 11 posts
- Joined:
- Offline
tamte
to group everything that is not in group yet you can create Group SOP and in the Base Group type:!?*darkdark132this can be very inefficient, if your groups don't need to overlap consider using attributes instead
have much groups(maybe group1,group2 to group100)
thanks, !?* can be use in any group like SOP?
-
- darkdark132
- Member
- 11 posts
- Joined:
- Offline
tamte
to group everything that is not in group yet you can create Group SOP and in the Base Group type:!?*darkdark132this can be very inefficient, if your groups don't need to overlap consider using attributes instead
have much groups(maybe group1,group2 to group100)
and,i find a bug in attribuewrangle:
string magroup = detailintrinsic(0, “primitivegroups”);
int sss = len(magroup);
setprimgroup(0, “ss”, @primnum, 1);
for(int i=0;i<sss;i++)
{if (inprimgroup(0,magroup,@primnum))
{setprimgroup(0, “ss”, @primnum, 0);}
};
it work well,and make not in group prim to a group named ss
but if you add a line:
string magroup = detailintrinsic(0, “primitivegroups”);
int sss = len(magroup);
setprimgroup(0, “ss”, @primnum, 1);
for(int i=0;i<sss;i++)
{if (inprimgroup(0,magroup,@primnum))
{setprimgroup(0, “ss”, @primnum, 0);}
};
@group_ss=0;
show the group ss in spreadsheet,it not bo zero
but if you add a prim attribuewrangle
cut @group_ss=0; to this
now show the group ss in spreadsheet,it be zero,correct
so i think have a bug between setprimgroup and @group_name
-
- darkdark132
- Member
- 11 posts
- Joined:
- Offline
-
- tamte
- Member
- 9380 posts
- Joined: July 2007
- Offline
darkdark132should work in any place that accepts group patterns
thanks, !?* can be use in any group like SOP?
darkdark132it's not a bug, but how VEX executes functions that are able to write to noncurrent element like setprimgroup() or setpointattrib(), …
so i think have a bug between setprimgroup and @group_name
they are queueued at the end and executed as a single threaded process as multiple ones can write to the ame element, that's why they win over your s@group_ss = 0 that is seemingly supposed to execute afterwards
while it's not thechnically a bug it's definitely not intuitive and requires some acceptance of how it works
darkdark132use code block, not only you can use special characters in there it's also much cleaner and safer way to share code as it's copy/paste friendly
i can't type array symbol
like this:
string magroup[] = detailintrinsic(0, “primitivegroups”);
Edited by tamte - Feb. 6, 2020 22:17:34
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- Quick Links

