algorithmic modeling for Rhino
I want to be able to move a point in the x direction with a number slider.
but the problem is:
the numeric domain is dynamic! it changes with the changing of other parameters.
It's not like Numeric domain: Min = a, Max = b (a and b are "fixed" numbers)
It's like Numeric domain: Min = (it can be c,d,e,f,g,...) Max = the same ...
Is this possible somehow? ...
Thank you in advance
Tags:
http://www.grasshopper3d.com/forum/topics/about-number-slider
"Reply by williamwong on November 6, 2011 at 12:32am
Yup, you'll want the Remap component. Create a domain using the min and max inputs, then feed that into your target domain in the remap component. I usually then use a number slider with the defaults from 0 to 1 to be the V, which will go through your full span of min and max values."
Done :)
x<z<y will not work. The way expressions are evaluated is one step at a time. The expression x<z<y has three variables and (x, y & z) and two operators (<). There will thus be a total of two steps to evaluating this expression.
First the leftmost < operator will be evaluated. This results in either true or false depending on whether x is less than z. Then the result of this step is compared to y. However, True=1 and False=0 so all you're doing now is seeing whether True or False are smaller than y.
Another way to look at this is to add the proper precedence brackets:
(x<z)<y
After step 1 has been completed, it will now look like:
(True)<y
-or-
(False)<y
If you want to compare these two, you'll need to use a third operator which combines the boolean result of both smaller than operators:
(x<z) And (z<y)
--
David Rutten
david@mcneel.com
Poprad, Slovakia
Thank you :)
Welcome to
Grasshopper
© 2024 Created by Scott Davidson. Powered by