I've run into a problem.
I'm using a primitive wrangle with a minpos(geo, group, position) function, where I'd like to limit the Geometry used in the minpos function to the current primitive being evaluated in the primitive wrangle.
The documentation ways, `ad hoc` group creation inside this function should be possible with @, but “the @ may need to be escaped with a backslash in a Wrangle snippet”.
What I tried is: “\@primnum”, but that didn't work.
If anyone knows how this code should look, so it works, I'd really appreciate an example of how escaping with a backslash should work or how to limit the Geometry in the minpos function to just the single primitive, that's being evaluated right now.
Thanks.
Cheers,
Ivan
what does escape @ with a backslash mean in VEX?
1944 2 1-
- ivanmalek
- Member
- 143 posts
- Joined: Sept. 2017
- Offline
-
- tamte
- Member
- 9379 posts
- Joined: July 2007
- Offline
it didnt work because primnum is not an attribute, you simply need to put a string that would be valid in a group parameter
and @primnum is not, not even @primnum=1, but you can directly type 1 or 1-10
so to get the same you can just use itoa(@primnum) so that it inserts string version of your current prim like “1” and use that as a group for example
of course you can use adhoc groups if you want to group by some existing attribute also and I think nowadays you don't even have to escape the @
and @primnum is not, not even @primnum=1, but you can directly type 1 or 1-10
so to get the same you can just use itoa(@primnum) so that it inserts string version of your current prim like “1” and use that as a group for example
of course you can use adhoc groups if you want to group by some existing attribute also and I think nowadays you don't even have to escape the @
Edited by tamte - Aug. 5, 2020 13:03:40
Tomas Slancik
CG Supervisor
Framestore, NY
CG Supervisor
Framestore, NY
-
- ivanmalek
- Member
- 143 posts
- Joined: Sept. 2017
- Offline
-
- Quick Links

