algorithmic modeling for Rhino
I have a bunch of planar surfaces, but the direction of the surface ( normals ) are not consistently pointing either outward or inward, it is a combination.
Is there an easy way in GH to change the normal direction of the surfaces, in such a way that they all point either outward or inward ( meaning, some will change some will stay the same ) ?
thanks
M
Tags:
Surface>Utilities>Flip
that seems to flip all of them, what I am looking for is to find a way to flip some of them so that all of them face the same way, does that make sense ? I have difficulties conceptualizing what to assign or how to go about to select the ones that are different. is it a list thing or can I select the orientation direction towards a centerpoint or something like that
M
If you have one surface you can always identify as being oriented correctly, you can feed it into the "g" input on the flip, and it will only flip those that aren't oriented in a similar direction. Otherwise, if you have a guide vector that's pointed generally in the correct direction that you can use to compare your other surfaces to, then you should extract all of their normals, do a vector angle test between them and your guide vector, and pass this value to a conditional expression to generate an index for a "pick 'n' choose" component: If(x>Pi/2,0,1). Run your surfaces through the flip component, and then feed your flipped surfaces into the 0 input of pick 'n' choose and your original list into the 1 input.
You can´t believe how much you´ve helped me! Thanks!
Welcome to
Grasshopper
Added by Parametric House 0 Comments 0 Likes
Added by Parametric House 0 Comments 0 Likes
© 2024 Created by Scott Davidson.
Powered by