Grasshopper

algorithmic modeling for Rhino

hello all,

 

Probably pretty simple but I cannot find the answer. I'd like to know, is here anyway to take a unitary value like "distance", an convert it into into just raw numeric value to be connected to another node.

 

IE: I'd like to used a distance value to specify curve degrees and my network will not allow a direct connection from distance to degrees.

 

Thank You

 

 

Views: 192

Replies to This Discussion

Could you be more specific about how GH "doesn't allow a direct connection"?

GH doesn't know about the meaning, unit or origin of the numbers you connect. It doesn't care even about data type and instead tries to find a suitable translation if you connect, say a point output to a number input.

Numbers are numbers. A distance of 1.0 when plugged into a Rotate component will probably result in a rotational angle of 1.0. These could be radians or degrees depending on how the angle parameter is set up. 

If you want some other conversion metric (i.e.a distance of one equals 0.7 degrees for example) then you need to use some logic that performs this conversion. A Multiply component wit 0.7 should suffice.

--

David Rutten

david@mcneel.com

Poprad, Slovakia

RSS

About

Translate

Search

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service