algorithmic modeling for Rhino
Greetings fellow Grasshopper users,
I am working on a studio project which involves explorations of point fields derived from different input systems. These point fields will end up being a driver for spatial studies farther down the road, but I digress; on to my Grasshopper script:
I've built a Grasshopper script that will display a point field for a given topography map (curves extracted from contour lines). The idea here is to display higher levels of density where the highest slopes are within a given topo map.
The file works, but I'm wondering if there is a simpler way of going about this, since my file contains so much redundant info (open the cluster "Pt:50" to see what I mean). My Grasshopper Kung-Fu skills aren't anywhere near expert yet, so I defer to the experts out there for a simpler solution. Here's my breakdown:
1. Start at curve start point, and find closest point within the group of curves.
2. Get distance to that closest point, and find second point along said curve at that distance.
3. Repeat process along curve starting at each new point at each new process.
Thanks in advance for any suggestions/comments!
Cheers,
cb
Tags:
Hi Christopher,
if you want your point distribution to be exactly like the algorithm described (measure distance to nearest curve, add point on curve based on that distance, repeat until end of curve has been reached), then it will be quite difficult. This is an iterative process where the next iteration depends on the results in the previous one. Grasshopper is notoriously bad at this sort of looping. If you want to solve it cleanly like this, then you'll either have to use HoopSnake or custom code (see attached).
If you're willing to consider other kinds of point distribution algorithms then it would open a few doors that may be interesting. Are you?
--
David Rutten
david@mcneel.com
Tirol, Austria
Thanks for the quick response; I'm definitely interested in other kinds of point distribution; I'm using this uni project to jump headfirst into all things related to these issues so I can get a firm hold on how they work within the program. Any and all paths/methods are welcome.
What doors can be opened?
cb
Well, I thought this might work, but it doesn't. The basic idea was:
The contouring is causing all kinds of horrible side-effects though...
--
David Rutten
david@mcneel.com
Tirol, Austria
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