algorithmic modeling for Rhino
Can someone please explain the string syntax when using a Mask expression for a path compare component in grasshopper? Also, what is the sytax when adding an expression as an argument to a parameter component such as a point parameter?
thanks
Tags:
[in passing]
Regular expressions are strictly textual; they describe a set of strings which a finite state automaton will accept. The basic idea came from Bell Labs. The original set of automata described by regexs had no backtrack and no memory. Later versions included backtrack. I suspect that Perl regexs are in fact Turing-complete, and can in principle implement any program. (Wikipedia, it turns out, covers this ground fairly well.)
In any event, you wanted a different sort of pattern matching. Now, I need to figure it out.
is there any way for me to make a series of series and pass that to a mask...
i have a tree with 89 main branches
i want to group them into sets of 3 [88,54,20],[87,53,19],...etc
i've been trying to define masks dynamically with series, but can't manage to get decent results unless the tree is basically one dimentional...
so i think it would be great if the compare mask could take an input of a list or a string, which i could then place into the mask:
like if a pass a list of 3 numbers into M on the compare i could make an expression for the M :
{0;M;*} ... and since i passed in [88,54,20] to M it would get internally parsed to:
{0;[88,54,20];*}
are there general string manipulation tools that I could use to do that stuff? or could i manage to create a mask in VB script somehow that i could pass in to the compare?
cheers,
gotjosh
http://www.grasshopper3d.com/profiles/blogs/series-branch-selector
answered my own question... but maybe someone knows a better way?
David,
It's been a while since this was updated. I couldn't find anyone asking this question but if you don't mind refreshing this post it would be great. I noticed that most of the masks described in here would not work with the latest GH. For example to get a range you used an example like this: {0;[0-10];0} while now it would have to be this: {0;(0~10);0} which is quite different. I honestly just kept trying different things until it worked but it would be nice to have a good set of working masks available for the latest GH.
Thank you!
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson. Powered by