Grasshopper

algorithmic modeling for Rhino

Hi All

 

After trying over 24hrs of trying to crack a code i have run out of workflows so asking here...

 

Does anyone have any ideas on how to find the closest point/s on a closed surface from a defined point on that surface. I have a working code for an open surface but yet to find  a way to rebuild the logic so it work on a closed surface.

 

In the attached the code the surface is reparameterized surface but this is only beacuse the test is using an MD Slider

 

Thank

Matt

Views: 1975

Attachments:

Replies to This Discussion

My pleasure. Yes, maybe the last two examples are faster.

Maybe you prefer one of these other two methods, based one on taxicab distance and the other on wrapped UV coordinates distance.

 

method 4:
UV taxi
method 5:
UV wrap
jumps in U and V jumps in U and V
grid distance on U and V taken separately distance in U and V coordinates
similar to the first example similar to the first example
Attachments:

Wow... Both seem Perfect and rather quicker than Geodesic. How similar are these 2 methods above as the Function seems to be quite similar.

 

In the 5th method all i need to remove from the expression is R≥ to get the distance between points. then cull these numbers after.

 

I understand they work great on a standard torus but as i am yet to full understand the expressions i though i would ask would they work on a "organic" Torus..(One i have deformed a re-shaped in T-splines though still a single NURBS Surface and still containing closed seems

 

Some think like this.

Thanks for all Your Help

Matt

> In the 5th method all i need to remove from the expression is R≥ to get the distance between points. then cull these numbers after.

 

We do not get the real-world distances there, as we are measuring UVs. We get the distance calculated from UV-to-UV, and measured either in "aerial" mode or "like in a taxi ride" (see link above for a picture).

RSS

About

Translate

Search

© 2024   Created by Scott Davidson.   Powered by

Badges  |  Report an Issue  |  Terms of Service